-
Notifications
You must be signed in to change notification settings - Fork 0
Tab bar styling adjustment #38
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from 10 commits
Commits
Show all changes
11 commits
Select commit
Hold shift + click to select a range
2d3a6f9
Made fitness center images stretchy headers
caitlynjin 1b57c23
Modified gym images as stretchy headers
caitlynjin 18c2f6e
Merge branch 'caitlyn/issues' of github.com:cuappdev/uplift-ios-swift…
caitlynjin 601f5b6
Adjusted font/color on tab bar and added divider
caitlynjin 5c3822b
Merge branch 'caitlyn/fix-hours' into caitlyn/stretchy-header
caitlynjin ae2f5f9
Update Package.resolved
caitlynjin b6fc9c7
Merge branch 'caitlyn/stretchy-header' into caitlyn/tab-design
caitlynjin 060cb13
Addressed Vin's comments
caitlynjin b2b2072
Update project.pbxproj
caitlynjin 1283313
Merge branch 'main' into caitlyn/tab-design
caitlynjin 48a5504
Update Package.resolved
caitlynjin File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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,66 @@ | ||
| ## Overview | ||
|
|
||
| TODO | ||
|
|
||
| ## Changes Made | ||
|
|
||
| ### Change 1 | ||
|
|
||
| - TODO | ||
| - TODO | ||
|
|
||
| ### Change 2 | ||
|
|
||
| - TODO | ||
| - TODO | ||
|
|
||
| ## Test Coverage | ||
|
|
||
| - TODO | ||
|
|
||
| ## Next Steps (optional) | ||
|
|
||
| TODO | ||
|
|
||
| ## Related PRs or Issues (optional) | ||
|
|
||
| TODO | ||
|
|
||
| ## Screenshots (optional) | ||
|
|
||
| <!-- use the following for videos --> | ||
| <details> | ||
| <summary>TODO</summary> | ||
| <table> | ||
| <tr> | ||
| <td>Before</td> | ||
| <td>After</td> | ||
| </tr> | ||
| <tr> | ||
| <td><video src="enterurlhere" type="video/mp4"></td> | ||
| <td><video src="enterurlhere" type="video/mp4"></td> | ||
| </tr> | ||
| </table> | ||
| </details> | ||
|
|
||
| <!-- use the following for images --> | ||
| <details> | ||
| <summary>TODO</summary> | ||
| <table> | ||
| <tr> | ||
| <td>Before</td> | ||
| <td>After</td> | ||
| </tr> | ||
| <tr> | ||
| <td><img src="enterurlhere" width="300px" height="auto"></td> | ||
| <td><img src="enterurlhere" width="300px" height="auto"></td> | ||
| </tr> | ||
| </table> | ||
| </details> | ||
|
|
||
| <!-- use the following if there is no before/after --> | ||
| <details> | ||
| <summary>TODO</summary> | ||
| <img src="enterurlhere" width="300px" height="auto"> | ||
| <video src="enterurlhere" type="video/mp4"> | ||
| </details> | ||
This file contains hidden or 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 hidden or 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
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains hidden or 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,37 @@ | ||
| // | ||
| // StretchyHeaderModifier.swift | ||
| // Uplift | ||
| // | ||
| // Created by Caitlyn Jin on 2/11/24. | ||
| // Copyright © 2024 Cornell AppDev. All rights reserved. | ||
| // | ||
|
|
||
| import SwiftUI | ||
|
|
||
| /// A view modifier that applies a stretchy effect to the header image. | ||
| struct StretchyModifier: ViewModifier { | ||
|
|
||
| var geometryProxy: GeometryProxy | ||
|
|
||
| func body(content: Content) -> some View { | ||
| let minY = geometryProxy.frame(in: .global).minY | ||
| let originY = geometryProxy.frame(in: .global).origin.y | ||
| let height = geometryProxy.size.height | ||
|
|
||
| content | ||
| .frame(height: minY > 0 ? height + originY : height) | ||
| .clipped() | ||
| .offset(y: minY > 0 ? -minY : 0) | ||
| } | ||
|
|
||
| } | ||
|
|
||
| extension View { | ||
|
|
||
| @ViewBuilder | ||
| func stretchy(_ gp: GeometryProxy) -> some View { | ||
| self | ||
| .modifier(StretchyModifier(geometryProxy: gp)) | ||
| } | ||
|
|
||
| } |
This file contains hidden or 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 hidden or 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
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.