-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Dan Eden
committed
Jul 2, 2024
1 parent
59900eb
commit 510b0bb
Showing
10 changed files
with
78 additions
and
58 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
// | ||
// View+MaterialListRowBackground.swift | ||
// Solstice | ||
// | ||
// Created by Dan Eden on 01/07/2024. | ||
// | ||
|
||
import SwiftUI | ||
|
||
struct MateriaListRowBackground: ViewModifier { | ||
func body(content: Content) -> some View { | ||
content | ||
#if os(watchOS) | ||
.modify { content in | ||
if #available(watchOS 10, *) { | ||
content | ||
.listRowBackground( | ||
Color.clear.background( | ||
.ultraThinMaterial, | ||
in: RoundedRectangle(cornerRadius: 12) | ||
) | ||
) | ||
} else { | ||
content | ||
.listRowBackground( | ||
Color.clear.background( | ||
.background, | ||
in: RoundedRectangle(cornerRadius: 12) | ||
) | ||
) | ||
} | ||
} | ||
#endif | ||
} | ||
} | ||
|
||
extension View { | ||
func materialListRowBackground() -> some View { | ||
return self.modifier(MateriaListRowBackground()) | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.