Skip to content

Commit 78fa0a0

Browse files
committed
Auto merge of #4356 - Turbo87:github-svg, r=Turbo87
Remove duplicate GitHub logo SVG There is no need to have this twice... 😅
2 parents cdab896 + 762d043 commit 78fa0a0

File tree

8 files changed

+24
-30
lines changed

8 files changed

+24
-30
lines changed

app/components/crate-sidebar/link.hbs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
{{#if this.isDocsRs}}
55
{{svg-jar "docs-rs" local-class="icon" data-test-icon="docs-rs"}}
66
{{else if this.isGitHub}}
7-
{{svg-jar "GitHub-Mark" local-class="icon" data-test-icon="github"}}
7+
{{svg-jar "github" local-class="icon" data-test-icon="github"}}
88
{{else}}
99
{{svg-jar "link" local-class="icon" data-test-icon="link"}}
1010
{{/if}}

app/styles/team.module.css

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,15 @@
2424

2525
.github-link {
2626
margin-left: 16px;
27+
28+
&, &:hover {
29+
color: var(--main-color);
30+
}
31+
32+
svg {
33+
width: 32px;
34+
height: 32px;
35+
}
2736
}
2837

2938
.results-meta {

app/styles/user.module.css

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,17 @@
77
}
88
}
99

10+
.github-link {
11+
&, &:hover {
12+
color: var(--main-color);
13+
}
14+
15+
svg {
16+
width: 32px;
17+
height: 32px;
18+
}
19+
}
20+
1021
.results-meta {
1122
display: flex;
1223
align-items: center;

app/templates/team.hbs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
{{ this.model.team.org_name }}
77
</h1>
88
<UserLink @user={{this.model.team}} local-class="github-link" data-test-github-link>
9-
<img alt="GitHub profile" title="GitHub profile" src="/assets/GitHub-Mark.svg">
9+
{{svg-jar "github" alt="GitHub profile"}}
1010
</UserLink>
1111
</div>
1212
<h2 data-test-team-name>

app/templates/user.hbs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@
33
<h1 data-test-username>
44
{{ this.model.user.login }}
55
</h1>
6-
<UserLink @user={{this.model.user}} data-test-user-link>
7-
<img alt="GitHub profile" title="GitHub profile" src="/assets/GitHub-Mark.svg">
6+
<UserLink @user={{this.model.user}} local-class="github-link" data-test-user-link>
7+
{{svg-jar "github" alt="GitHub profile"}}
88
</UserLink>
99
</PageHeader>
1010

public/assets/GitHub-Mark.svg

Lines changed: 0 additions & 10 deletions
This file was deleted.

tests/acceptance/team-page-test.js

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -31,14 +31,6 @@ module('Acceptance | team page', function (hooks) {
3131
assert.dom('[data-test-heading] [data-test-github-link]').hasAttribute('href', 'https://github.com/org_test');
3232
});
3333

34-
test('github link has image in team header', async function (assert) {
35-
this.server.loadFixtures();
36-
37-
await visit('/teams/github:org:thehydroimpulse');
38-
39-
assert.dom('[data-test-heading] [data-test-github-link] img').hasAttribute('src', '/assets/GitHub-Mark.svg');
40-
});
41-
4234
test('team organization details has github profile icon', async function (assert) {
4335
this.server.loadFixtures();
4436

tests/acceptance/user-page-test.js

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -30,14 +30,6 @@ module('Acceptance | user page', function (hooks) {
3030
assert.dom('[data-test-heading] [data-test-user-link]').hasAttribute('href', 'https://github.com/thehydroimpulse');
3131
});
3232

33-
test('github link has image in user header', async function (assert) {
34-
this.server.loadFixtures();
35-
36-
await visit('/users/thehydroimpulse');
37-
38-
assert.dom('[data-test-heading] [data-test-user-link] img').hasAttribute('src', '/assets/GitHub-Mark.svg');
39-
});
40-
4133
test('user details has github profile icon', async function (assert) {
4234
this.server.loadFixtures();
4335

0 commit comments

Comments
 (0)