-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Improved overall tab style to feel more native to macOS * Fixed lint error * More lint error fixes * More lint error fixes * More liner error fixes * Create CONTRIBUTING.md * Update CONTRIBUTING.md * Update CONTRIBUTING.md * Update CONTRIBUTING.md * Fix "Welcome to CodeEdit" Main Menu item (#106) * Fix data format (#105) * Allow opening of `public.item` instead of `public.source-code` * Handle errors * Message Preview when opening the non coding file (#102) * Cleaned up the typography for Welcome Screen * Added support for more code editor themes * Revert "Added support for more code editor themes" This reverts commit 8139217. * Revert "Cleaned up the typography for Welcome Screen" This reverts commit 78b748b. * Update the error message to be more informative when trying to open files that are not code related * Added language translations for editor error and support for the Afrikaans Language * Fixed localization changes in Russian and Belarusian * Updated the editor error string to be short and sweet * Update to editor error for file types. * Change document types priority, prioritize workspace over source code file to fix #110 * Fix multiple welcome window * Fix version localization key (#120) * Improved overall tab style to feel more native to macOS * Fixed lint error * More lint error fixes * Replicating aesthetic and behavior of standard tabs. Removed wrapper component so that code is more straightforward. * Update WorkspaceCodeFileView.swift Resolved conflicts * Fixed lint errors and animations * Added PressActionsModifier file to project * Added PressActionsModifier.swift * Fixed lint error * Fixed lint error Co-authored-by: Luke <[email protected]> Co-authored-by: Pavel Kasila <[email protected]> Co-authored-by: Nanashi Li <[email protected]> Co-authored-by: Ziyuan Zhao <[email protected]>
- Loading branch information
1 parent
adc8036
commit c07955c
Showing
10 changed files
with
219 additions
and
161 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
// | ||
// Created by Gabriel Theodoropoulos on 1/11/20. | ||
// | ||
|
||
import SwiftUI | ||
|
||
struct PressActions: ViewModifier { | ||
var onPress: () -> Void | ||
var onRelease: () -> Void | ||
func body(content: Content) -> some View { | ||
content | ||
.simultaneousGesture( | ||
DragGesture(minimumDistance: 0) | ||
.onChanged({ _ in | ||
onPress() | ||
}) | ||
.onEnded({ _ in | ||
onRelease() | ||
}) | ||
) | ||
} | ||
} | ||
|
||
extension View { | ||
func pressAction(onPress: @escaping (() -> Void), onRelease: @escaping (() -> Void)) -> some View { | ||
modifier(PressActions(onPress: { | ||
onPress() | ||
}, onRelease: { | ||
onRelease() | ||
})) | ||
} | ||
} |
This file was deleted.
Oops, something went wrong.
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
Oops, something went wrong.