]> Untitled Git - lemmy.git/commitdiff
Adding an external link icon. #530
authorDessalines <tyhou13@gmx.com>
Sat, 15 Feb 2020 03:28:29 +0000 (22:28 -0500)
committerDessalines <tyhou13@gmx.com>
Sat, 15 Feb 2020 03:29:17 +0000 (22:29 -0500)
ui/src/components/post-listing.tsx
ui/src/components/symbols.tsx

index 4dea4d86c70a452921adf866c27d55e9e29d599b..1b8042f8a36830ef2638e0ebf3fd6b555d1fa938 100644 (file)
@@ -188,6 +188,9 @@ export class PostListing extends Component<PostListingProps, PostListingState> {
                   title={post.url}
                 >
                   {new URL(post.url).hostname}
+                  <svg class="ml-1 icon">
+                    <use xlinkHref="#icon-external-link"></use>
+                  </svg>
                 </a>
               </small>
             )}
index 829201e4ca3e715eb494dfaefabb4ebe31aa6949..0870efd71d87d7e1e125bb0d800f2d1a7b366fff 100644 (file)
@@ -15,6 +15,10 @@ export class Symbols extends Component<any, any> {
         xmlnsXlink="http://www.w3.org/1999/xlink"
       >
         <defs>
+          <symbol id="icon-external-link" viewBox="0 0 24 24">
+            <title>external-link</title>
+            <path d="M17 13v6c0 0.276-0.111 0.525-0.293 0.707s-0.431 0.293-0.707 0.293h-11c-0.276 0-0.525-0.111-0.707-0.293s-0.293-0.431-0.293-0.707v-11c0-0.276 0.111-0.525 0.293-0.707s0.431-0.293 0.707-0.293h6c0.552 0 1-0.448 1-1s-0.448-1-1-1h-6c-0.828 0-1.58 0.337-2.121 0.879s-0.879 1.293-0.879 2.121v11c0 0.828 0.337 1.58 0.879 2.121s1.293 0.879 2.121 0.879h11c0.828 0 1.58-0.337 2.121-0.879s0.879-1.293 0.879-2.121v-6c0-0.552-0.448-1-1-1s-1 0.448-1 1zM10.707 14.707l9.293-9.293v3.586c0 0.552 0.448 1 1 1s1-0.448 1-1v-6c0-0.136-0.027-0.265-0.076-0.383s-0.121-0.228-0.216-0.323c-0.001-0.001-0.001-0.001-0.002-0.002-0.092-0.092-0.202-0.166-0.323-0.216-0.118-0.049-0.247-0.076-0.383-0.076h-6c-0.552 0-1 0.448-1 1s0.448 1 1 1h3.586l-9.293 9.293c-0.391 0.391-0.391 1.024 0 1.414s1.024 0.391 1.414 0z"></path>
+          </symbol>
           <symbol id="icon-coffee" viewBox="0 0 24 24">
             <title>coffee1</title>
             <path d="M17 19h-12c-0.553 0-1-0.447-1-1s0.447-1 1-1h12c0.553 0 1 0.447 1 1s-0.447 1-1 1z"></path>