Skip to content

Commit

Permalink
feat(Icon): support new table edit icon
Browse files Browse the repository at this point in the history
Also cleanup

ISSUES CLOSED: #1759
  • Loading branch information
benjamincharity committed Oct 25, 2019
1 parent 282dc1a commit a7134d6
Show file tree
Hide file tree
Showing 9 changed files with 105 additions and 30 deletions.
29 changes: 27 additions & 2 deletions terminus-ui/icon/src/custom-icons/csv.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,33 @@
export const CSV_ICON = `
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
<g transform="translate(4 2)">
<path d="M10,0 L2,0 C0.9,0 0.01,0.9 0.01,2 L0,18 C0,19.1 0.89,20 1.99,20 L14,20 C15.1,20 16,19.1 16,18 L16,6 L10,0 Z M2,18 L2,2 L9,2 L9,7 L14,7 L14,18 L2,18 Z"/>
<path d="M2.77543454,13.9332157 C2.77543454,13.3050802 2.94385695,12.8209674 3.28070682,12.480863 C3.57361975,12.1846955 3.9462645,12.0366139 4.39865225,12.0366139 C5.00400564,12.0366139 5.44662299,12.2351408 5.72651757,12.6322006 C5.8811105,12.8551399 5.96410125,13.0788894 5.97549231,13.303456 L5.22368621,13.303456 C5.17486739,13.1309629 5.11221751,13.0007813 5.03573469,12.9129074 C4.89904199,12.7566872 4.69644692,12.6785782 4.4279434,12.6785782 C4.154558,12.6785782 3.93894477,12.7888257 3.78109724,13.0093241 C3.62324972,13.2298224 3.54432714,13.5418514 3.54432714,13.9454203 C3.54432714,14.3489892 3.62772471,14.6512546 3.79452235,14.8522254 C3.96131999,15.0531962 4.17327187,15.1536801 4.43038433,15.1536801 C4.69400596,15.1536801 4.89497377,15.0674348 5.03329376,14.8949417 C5.10977658,14.8021859 5.1732401,14.6630543 5.22368621,14.4775428 L5.96816952,14.4775428 C5.90307776,14.8697207 5.73668944,15.1886655 5.46899957,15.4343869 C5.20130969,15.6801083 4.85836262,15.8029672 4.44014804,15.8029672 C3.92266853,15.8029672 3.51585112,15.6369857 3.2196836,15.3050177 C2.92351608,14.9714224 2.77543454,14.5141597 2.77543454,13.9332157 Z M7.31068041,14.5922665 C7.33346253,14.7566232 7.37821244,14.879482 7.4449315,14.9608467 C7.56697856,15.1089305 7.77608271,15.1829713 8.07225022,15.1829713 C8.24962528,15.1829713 8.39363864,15.163444 8.50429464,15.124389 C8.71421557,15.0495334 8.81917446,14.9104019 8.81917446,14.7069901 C8.81917446,14.5881977 8.76710183,14.4962569 8.66295501,14.4311652 C8.55880819,14.3677007 8.39526759,14.3115599 8.17232831,14.2627411 L7.7915434,14.1773086 C7.41726577,14.0926893 7.15852989,14.0007485 7.01532802,13.9014836 C6.7728612,13.7354996 6.65162961,13.4759501 6.65162961,13.1228273 C6.65162961,12.8006231 6.76879303,12.5329372 7.00312337,12.3197617 C7.23745372,12.1065862 7.58162125,12 8.03563629,12 C8.41479581,12 8.73821565,12.1004839 9.00590552,12.3014547 C9.2735954,12.5024255 9.4139474,12.7941136 9.42696576,13.1765277 L8.70445081,13.1765277 C8.69143245,12.9600976 8.59705081,12.8063206 8.42130305,12.7151922 C8.30413788,12.6549823 8.15849725,12.6248778 7.98437678,12.6248778 C7.79072879,12.6248778 7.63613817,12.6639323 7.5206003,12.7420424 C7.40506242,12.8201525 7.34729435,12.9291796 7.34729435,13.0691269 C7.34729435,13.1976831 7.40424878,13.293692 7.51815937,13.3571565 C7.5913876,13.3994661 7.74760549,13.4490978 7.98681771,13.5060531 L8.60681365,13.6549498 C8.87857176,13.7200415 9.08360773,13.8071005 9.22192773,13.9161292 C9.43673055,14.0853678 9.54413034,14.3302718 9.54413034,14.6508488 C9.54413034,14.9795622 9.41842376,15.2525367 9.16700683,15.4697804 C8.9155899,15.6870242 8.5604383,15.7956444 8.10154137,15.7956444 C7.63288068,15.7956444 7.26430411,15.6886514 6.99580059,15.4746623 C6.72729707,15.2606731 6.59304732,14.9665441 6.59304732,14.5922665 L7.31068041,14.5922665 Z M12.2071838,12.1049599 L12.988281,12.1049599 L11.7604938,15.7028891 L11.0501835,15.7028891 L9.83460088,12.1049599 L10.6376665,12.1049599 L11.4187637,14.8363594 L12.2071838,12.1049599 Z"/>
<path d="M10,0 L2,0 C0.9,0 0.01,0.9 0.01,2 L0,18 C0,19.1 0.89,20 1.99,20 L14,20 C15.1,20 16,19.1 16,18 L16,6 L10,0 Z M2,18 L2,2 L9,2
L9,7 L14,7 L14,18 L2,18 Z"/>
<path d="M2.77543454,13.9332157 C2.77543454,13.3050802 2.94385695,12.8209674 3.28070682,12.480863 C3.57361975,12.1846955
3.9462645,12.0366139 4.39865225,12.0366139 C5.00400564,12.0366139 5.44662299,12.2351408 5.72651757,12.6322006 C5.8811105,12.8551399
5.96410125,13.0788894 5.97549231,13.303456 L5.22368621,13.303456 C5.17486739,13.1309629 5.11221751,13.0007813 5.03573469,12.9129074
C4.89904199,12.7566872 4.69644692,12.6785782 4.4279434,12.6785782 C4.154558,12.6785782 3.93894477,12.7888257 3.78109724,13.0093241
C3.62324972,13.2298224 3.54432714,13.5418514 3.54432714,13.9454203 C3.54432714,14.3489892 3.62772471,14.6512546
3.79452235,14.8522254 C3.96131999,15.0531962 4.17327187,15.1536801 4.43038433,15.1536801 C4.69400596,15.1536801
4.89497377,15.0674348 5.03329376,14.8949417 C5.10977658,14.8021859 5.1732401,14.6630543 5.22368621,14.4775428 L5.96816952,14.4775428
C5.90307776,14.8697207 5.73668944,15.1886655 5.46899957,15.4343869 C5.20130969,15.6801083 4.85836262,15.8029672
4.44014804,15.8029672 C3.92266853,15.8029672 3.51585112,15.6369857 3.2196836,15.3050177 C2.92351608,14.9714224 2.77543454,14.5141597
2.77543454,13.9332157 Z M7.31068041,14.5922665 C7.33346253,14.7566232 7.37821244,14.879482 7.4449315,14.9608467
C7.56697856,15.1089305 7.77608271,15.1829713 8.07225022,15.1829713 C8.24962528,15.1829713 8.39363864,15.163444 8.50429464,15.124389
C8.71421557,15.0495334 8.81917446,14.9104019 8.81917446,14.7069901 C8.81917446,14.5881977 8.76710183,14.4962569
8.66295501,14.4311652 C8.55880819,14.3677007 8.39526759,14.3115599 8.17232831,14.2627411 L7.7915434,14.1773086
C7.41726577,14.0926893 7.15852989,14.0007485 7.01532802,13.9014836 C6.7728612,13.7354996 6.65162961,13.4759501 6.65162961,13.1228273
C6.65162961,12.8006231 6.76879303,12.5329372 7.00312337,12.3197617 C7.23745372,12.1065862 7.58162125,12 8.03563629,12 C8.41479581,12
8.73821565,12.1004839 9.00590552,12.3014547 C9.2735954,12.5024255 9.4139474,12.7941136 9.42696576,13.1765277 L8.70445081,13.1765277
C8.69143245,12.9600976 8.59705081,12.8063206 8.42130305,12.7151922 C8.30413788,12.6549823 8.15849725,12.6248778
7.98437678,12.6248778 C7.79072879,12.6248778 7.63613817,12.6639323 7.5206003,12.7420424 C7.40506242,12.8201525 7.34729435,12.9291796
7.34729435,13.0691269 C7.34729435,13.1976831 7.40424878,13.293692 7.51815937,13.3571565 C7.5913876,13.3994661 7.74760549,13.4490978
7.98681771,13.5060531 L8.60681365,13.6549498 C8.87857176,13.7200415 9.08360773,13.8071005 9.22192773,13.9161292
C9.43673055,14.0853678 9.54413034,14.3302718 9.54413034,14.6508488 C9.54413034,14.9795622 9.41842376,15.2525367
9.16700683,15.4697804 C8.9155899,15.6870242 8.5604383,15.7956444 8.10154137,15.7956444 C7.63288068,15.7956444 7.26430411,15.6886514
6.99580059,15.4746623 C6.72729707,15.2606731 6.59304732,14.9665441 6.59304732,14.5922665 L7.31068041,14.5922665 Z
M12.2071838,12.1049599 L12.988281,12.1049599 L11.7604938,15.7028891 L11.0501835,15.7028891 L9.83460088,12.1049599
L10.6376665,12.1049599 L11.4187637,14.8363594 L12.2071838,12.1049599 Z"/>
</g>
</svg>
`;
12 changes: 11 additions & 1 deletion terminus-ui/icon/src/custom-icons/engage.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,16 @@
/* eslint-disable max-len */
export const ENGAGE_ICON = `
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
<path fill-rule="evenodd" d="M13.584689 4.2754491C13.5344498 4.17365269 13.4641148 4.10239521 13.3736842 4.04131737L7.01339713.0814371257C6.74210526-.0814371257 6.40047847.0203592814 6.24976077.315568862 6.19952153.407185629 6.17942584.508982036 6.17942584.620958084L6.17942584 1.91377246.733492823 1.91377246C.331578947 1.91377246 0 2.27005988 0 2.71796407L0 6.44371257C0 6.89161677.331578947 7.24790419.733492823 7.24790419L6.17942584 7.24790419 6.17942584 8.54071856C6.17942584 8.87664671 6.43062201 9.15149701 6.74210526 9.15149701 6.84258373 9.15149701 6.93301435 9.12095808 7.01339713 9.07005988L13.3736842 5.11017964C13.6449761 4.94730539 13.7354067 4.57065868 13.584689 4.2754491zM19.2464115 9.98502994L13.8205742 9.98502994 13.8205742 8.50898204C13.8205742 8.23413174 13.6196172 8 13.3583732 8 13.2779904 8 13.1976077 8.02035928 13.1272727 8.07125749L6.47559809 12.2245509C6.24449761 12.3263473 6.1138756 12.591018 6.21435407 12.8556886 6.2645933 12.9778443 6.35502392 13.0796407 6.47559809 13.1L13.1272727 17.2532934C13.3483254 17.3958084 13.6296651 17.3041916 13.7602871 17.0598802 13.8004785 16.9886228 13.8205742 16.897006 13.8205742 16.8053892L13.8205742 15.3191617 19.2464115 15.3191617C19.6583732 15.3191617 20 14.9526946 20 14.4946108L20 10.8095808C20 10.351497 19.6583732 9.98502994 19.2464115 9.98502994z" transform="translate(2 3)"/>
<path fill-rule="evenodd" d="M13.584689 4.2754491C13.5344498 4.17365269 13.4641148 4.10239521 13.3736842
4.04131737L7.01339713.0814371257C6.74210526-.0814371257 6.40047847.0203592814 6.24976077.315568862 6.19952153.407185629
6.17942584.508982036 6.17942584.620958084L6.17942584 1.91377246.733492823 1.91377246C.331578947 1.91377246 0 2.27005988 0 2.71796407L0
6.44371257C0 6.89161677.331578947 7.24790419.733492823 7.24790419L6.17942584 7.24790419 6.17942584 8.54071856C6.17942584 8.87664671
6.43062201 9.15149701 6.74210526 9.15149701 6.84258373 9.15149701 6.93301435 9.12095808 7.01339713 9.07005988L13.3736842
5.11017964C13.6449761 4.94730539 13.7354067 4.57065868 13.584689 4.2754491zM19.2464115 9.98502994L13.8205742 9.98502994 13.8205742
8.50898204C13.8205742 8.23413174 13.6196172 8 13.3583732 8 13.2779904 8 13.1976077 8.02035928 13.1272727 8.07125749L6.47559809
12.2245509C6.24449761 12.3263473 6.1138756 12.591018 6.21435407 12.8556886 6.2645933 12.9778443 6.35502392 13.0796407 6.47559809
13.1L13.1272727 17.2532934C13.3483254 17.3958084 13.6296651 17.3041916 13.7602871 17.0598802 13.8004785 16.9886228 13.8205742
16.897006 13.8205742 16.8053892L13.8205742 15.3191617 19.2464115 15.3191617C19.6583732 15.3191617 20 14.9526946 20 14.4946108L20
10.8095808C20 10.351497 19.6583732 9.98502994 19.2464115 9.98502994z" transform="translate(2 3)"/>
</svg>
`;
6 changes: 5 additions & 1 deletion terminus-ui/icon/src/custom-icons/lightbulb.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,11 @@
export const LIGHTBULB_ICON = `
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
<g>
<path d="M9,21 C9,21.55 9.44999995,22 10,22 L14,22 C14.5500001,22 15,21.55 15,21 L15,20 L9,20 L9,21 Z M12,2 C8.13999999,2 5,5.14 5,9 C5,11.38 6.19,13.47 7.99999999,14.74 L7.99999999,17 C7.99999999,17.55 8.45000003,18 9.00000001,18 L15,18 C15.55,18 16,17.55 16,17 L16,14.74 C17.81,13.47 19,11.38 19,9 C19,5.14 15.86,2 12,2 Z M14.85,13.1 L13.9999999,13.7 L13.9999999,16 L10.0000001,16 L10.0000001,13.7 L9.15000005,13.1 C7.80000003,12.16 7,10.63 7,9 C7,6.24 9.23999998,4 12,4 C14.76,4 17,6.24 17,9 C17,10.63 16.2,12.16 14.85,13.1 Z"/>
<path d="M9,21 C9,21.55 9.44999995,22 10,22 L14,22 C14.5500001,22 15,21.55 15,21 L15,20 L9,20 L9,21 Z M12,2 C8.13999999,2 5,5.14
5,9 C5,11.38 6.19,13.47 7.99999999,14.74 L7.99999999,17 C7.99999999,17.55 8.45000003,18 9.00000001,18 L15,18 C15.55,18 16,17.55
16,17 L16,14.74 C17.81,13.47 19,11.38 19,9 C19,5.14 15.86,2 12,2 Z M14.85,13.1 L13.9999999,13.7 L13.9999999,16 L10.0000001,16
L10.0000001,13.7 L9.15000005,13.1 C7.80000003,12.16 7,10.63 7,9 C7,6.24 9.23999998,4 12,4 C14.76,4 17,6.24 17,9 C17,10.63
16.2,12.16 14.85,13.1 Z"/>
</g>
</svg>
`;
28 changes: 28 additions & 0 deletions terminus-ui/icon/src/custom-icons/logo-color.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
/* eslint-disable max-len */
export const LOGO_COLOR_ICON = `
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
<defs>
<radialGradient id="terminus-mark-icon-gradient-a" cx="44.984%" cy="44.749%" r="79.61%" fx="44.984%" fy="44.749%"
gradientTransform="matrix(.77654 .59506 -.63007 .7334 .382 -.149)">
<stop offset="0%" stop-color="#0098CE"/>
<stop offset="28.89%" stop-color="#0072C6"/>
<stop offset="57.81%" stop-color="#0065AC"/>
<stop offset="100%" stop-color="#00538A"/>
</radialGradient>
</defs>
<g fill="none" fill-rule="evenodd">
<polygon points="0 0 24 0 24 24 0 24"/>
<path fill="url(#terminus-mark-icon-gradient-a)" fill-rule="nonzero" d="M12.5094828,12.1879106 L15.8689156,11.0607065
C16.0108355,11.0099402 16.1612661,11.112335 16.1612661,11.2597834 L16.1612661,20.787989 C16.1612661,20.9050424 16.0638896,21
15.9438546,21 L12.5844218,21 C12.4643868,21 12.3670104,20.9050424 12.3670104,20.787989 L12.3670104,12.3868797 C12.3670104,12.297958
12.4238225,12.2185213 12.5094828,12.1879106 Z M5.00011053,14.848341 L5.00011053,20.7878813 C5.00011053,20.9049346
5.09748699,20.9998922 5.217522,20.9998922 L8.5444591,20.9998922 C8.66449411,20.9998922 8.76187057,20.9049346 8.76187057,20.7878813
L8.76187057,13.7516396 C8.76187057,13.6079637 8.61829279,13.5058923 8.47803089,13.5497604 L5.15109379,14.6465695 C5.0611228,14.6745933
5.00011053,14.7561857 5.00011053,14.848341 Z M16.0412311,3.25876793 L16.3248497,4.59658186 L5.13871449,8.37031222
C5.05504368,8.40200069 5,8.48046737 5,8.56798791 L5,11.4070162 C5,11.5532789 5.14833055,11.6556737 5.28980828,11.6069553
L17.1097195,7.63199241 L17.36659,8.72524464 C17.4056069,8.89112408 17.6189287,8.94684837 17.7377479,8.82225016 L21.9416259,4.41281028
C22.0573502,4.2914456 21.9919168,4.09333877 21.8253489,4.06057246 L16.2962226,3.00429011 C16.1418129,2.97400283 16.0066353,3.1088405
16.0412311,3.25876793 Z"/>
</g>
</svg>
`;
11 changes: 10 additions & 1 deletion terminus-ui/icon/src/custom-icons/logo.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,15 @@
/* eslint-disable max-len */
export const LOGO_ICON = `
<svg height="24" viewBox="0 0 24 24" width="24" xmlns="http://www.w3.org/2000/svg">
<path d="M12.5094828,12.1879106 L15.8689156,11.0607065 C16.0108355,11.0099402 16.1612661,11.112335 16.1612661,11.2597834 L16.1612661,20.787989 C16.1612661,20.9050424 16.0638896,21 15.9438546,21 L12.5844218,21 C12.4643868,21 12.3670104,20.9050424 12.3670104,20.787989 L12.3670104,12.3868797 C12.3670104,12.297958 12.4238225,12.2185213 12.5094828,12.1879106 Z M5.00011053,14.848341 L5.00011053,20.7878813 C5.00011053,20.9049346 5.09748699,20.9998922 5.217522,20.9998922 L8.5444591,20.9998922 C8.66449411,20.9998922 8.76187057,20.9049346 8.76187057,20.7878813 L8.76187057,13.7516396 C8.76187057,13.6079637 8.61829279,13.5058923 8.47803089,13.5497604 L5.15109379,14.6465695 C5.0611228,14.6745933 5.00011053,14.7561857 5.00011053,14.848341 Z M16.0412311,3.25876793 L16.3248497,4.59658186 L5.13871449,8.37031222 C5.05504368,8.40200069 5,8.48046737 5,8.56798791 L5,11.4070162 C5,11.5532789 5.14833055,11.6556737 5.28980828,11.6069553 L17.1097195,7.63199241 L17.36659,8.72524464 C17.4056069,8.89112408 17.6189287,8.94684837 17.7377479,8.82225016 L21.9416259,4.41281028 C22.0573502,4.2914456 21.9919168,4.09333877 21.8253489,4.06057246 L16.2962226,3.00429011 C16.1418129,2.97400283 16.0066353,3.1088405 16.0412311,3.25876793 Z"/>
<path d="M12.5094828,12.1879106 L15.8689156,11.0607065 C16.0108355,11.0099402 16.1612661,11.112335 16.1612661,11.2597834
L16.1612661,20.787989 C16.1612661,20.9050424 16.0638896,21 15.9438546,21 L12.5844218,21 C12.4643868,21 12.3670104,20.9050424
12.3670104,20.787989 L12.3670104,12.3868797 C12.3670104,12.297958 12.4238225,12.2185213 12.5094828,12.1879106 Z M5.00011053,14.848341
L5.00011053,20.7878813 C5.00011053,20.9049346 5.09748699,20.9998922 5.217522,20.9998922 L8.5444591,20.9998922 C8.66449411,20.9998922
8.76187057,20.9049346 8.76187057,20.7878813 L8.76187057,13.7516396 C8.76187057,13.6079637 8.61829279,13.5058923 8.47803089,13.5497604
L5.15109379,14.6465695 C5.0611228,14.6745933 5.00011053,14.7561857 5.00011053,14.848341 Z M16.0412311,3.25876793 L16.3248497,4.59658186
L5.13871449,8.37031222 C5.05504368,8.40200069 5,8.48046737 5,8.56798791 L5,11.4070162 C5,11.5532789 5.14833055,11.6556737
5.28980828,11.6069553 L17.1097195,7.63199241 L17.36659,8.72524464 C17.4056069,8.89112408 17.6189287,8.94684837 17.7377479,8.82225016
L21.9416259,4.41281028 C22.0573502,4.2914456 21.9919168,4.09333877 21.8253489,4.06057246 L16.2962226,3.00429011 C16.1418129,2.97400283
16.0066353,3.1088405 16.0412311,3.25876793 Z"/>
</svg>
`;
17 changes: 0 additions & 17 deletions terminus-ui/icon/src/custom-icons/logo_color.ts

This file was deleted.

7 changes: 7 additions & 0 deletions terminus-ui/icon/src/custom-icons/table-large-plus.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
export const TABLE_LARGE_PLUS = `
<svg height="24" viewBox="0 0 24 24" width="24" xmlns="http://www.w3.org/2000/svg">
<path d="m12.35 20h-2.35v-3h2.09c.12-.72.37-1.39.72-2h-2.81v-3h4v1.54c.58-.54 1.25-.93 2-1.19v-.35h4v.35c.75.26 1.42.65 2
1.19v-8.54c0-1.1-.9-2-2-2h-16c-1.1 0-2 .9-2 2v15c0 1.1.9 2 2 2h9.54c-.54-.58-.93-1.25-1.19-2m3.65-13h4v3h-4zm-6 0h4v3h-4zm-2
13h-4v-3h4zm0-5h-4v-3h4zm0-5h-4v-3h4zm9 4h2v3h3v2h-3v3h-2v-3h-3v-2h3z"/>
</svg>
`;
19 changes: 12 additions & 7 deletions terminus-ui/icon/src/icon.component.md
Original file line number Diff line number Diff line change
Expand Up @@ -94,10 +94,15 @@ Any icon with a -color suffix will not accept themes. Currently they accept a ba

### Available

| Name | Description | Example Usage |
|--------------:|:-------------------------------------------------------:|:----------------------------------|
| `csv` | A file with the text 'CSV' | Upload a CSV |
| `engage` | A right-pointing arrow stacked on a left-pointing arrow | Navigation for Engage product |
| `lightbulb` | A lightbulb | Pro-tip box |
| `logo` | Terminus logo, default is black, but accepts theme | Logo, negative logo |
| `logo_color` | Terminus logo in correct colors, does not accept theme | Logo like it is supposed to look |
| Name | Description | Example Usage |
|-------------------:|:--------------------------------------------------------|:---------------------------------|
| `csv` | A file with the text 'CSV' | Upload a CSV |
| `engage` | A right-pointing arrow stacked on a left-pointing arrow | Navigation for Engage product |
| `lightbulb` | A lightbulb | Pro-tip box |
| `logo` | Terminus logo, default is black, but accepts theme | Logo, negative logo |
| `logo_color` | Terminus logo in correct colors, does not accept theme | Logo like it is supposed to look |
| `table_large_plus` | A table icon with a plus sign | Editing table columns |




Loading

0 comments on commit a7134d6

Please sign in to comment.