Skip to content

Commit bd23623

Browse files
authored
Merge pull request #11 from lukepistrol/feat/add-github-icon
add github symbol
2 parents 6b62ebf + 5066c94 commit bd23623

File tree

13 files changed

+127
-0
lines changed

13 files changed

+127
-0
lines changed

Sources/CodeEditSymbols/CodeEditSymbols.swift

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@ public extension Image {
2323
static let breakpoint: Image = .init(symbol: "breakpoint")
2424
static let breakpoint_fill: Image = .init(symbol: "breakpoint.fill")
2525
static let customChevronUpChevronDown: Image = .init(symbol: "custom.chevron.up.chevron.down")
26+
static let github: Image = .init(symbol: "github")
2627

2728
// add static properties for your symbols above this line
2829

@@ -47,6 +48,7 @@ public extension NSImage {
4748
static let breakpoint: NSImage = .symbol(named: "breakpoint")
4849
static let breakpoint_fill: NSImage = .symbol(named: "breakpoint.fill")
4950
static let customChevronUpChevronDown: NSImage = .symbol(named: "custom.chevron.up.chevron.down")
51+
static let github: NSImage = .symbol(named: "github")
5052

5153
// add static properties for your symbols above this line
5254

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
{
2+
"info" : {
3+
"author" : "xcode",
4+
"version" : 1
5+
},
6+
"symbols" : [
7+
{
8+
"filename" : "github.svg",
9+
"idiom" : "universal"
10+
}
11+
]
12+
}

Sources/CodeEditSymbols/Symbols.xcassets/github.symbolset/github.svg

Lines changed: 99 additions & 0 deletions
Loading

Tests/CodeEditSymbolsTests/CodeEditSymbolsTests.swift

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,13 @@ final class CodeEditSymbolsTests: XCTestCase {
5959
assertSnapshot(matching: view, as: .image, record: record)
6060
}
6161

62+
func testCreateNSImageGitHub() {
63+
let image = NSImage.github
64+
let view = NSImageView(image: image)
65+
view.appearance = .init(named: .aqua)
66+
assertSnapshot(matching: view, as: .image, record: record)
67+
}
68+
6269
// MARK: - Image Tests
6370

6471
// MARK: VAULT
@@ -110,4 +117,11 @@ final class CodeEditSymbolsTests: XCTestCase {
110117
view.appearance = .init(named: .aqua)
111118
assertSnapshot(matching: view, as: .image(size: view.intrinsicContentSize), record: record)
112119
}
120+
121+
func testCreateImageGitHub() {
122+
let image = Image.github
123+
let view: NSView = NSHostingController(rootView: image).view
124+
view.appearance = .init(named: .aqua)
125+
assertSnapshot(matching: view, as: .image(size: view.intrinsicContentSize), record: record)
126+
}
113127
}
-1 Bytes
Loading
71 Bytes
Loading
12 Bytes
Loading
-1 Bytes
Loading
2.13 KB
Loading
-6 Bytes
Loading

0 commit comments

Comments
 (0)