-
Notifications
You must be signed in to change notification settings - Fork 403
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #28 from bowels/main
added devices restrictions from a12 and higher. Fixed UI buttons / Po…
- Loading branch information
Showing
8 changed files
with
378 additions
and
266 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
// | ||
// Fonts.swift | ||
// MLCChat | ||
// | ||
// Created by Roma iOS on 12.09.2023. | ||
// | ||
|
||
import Foundation | ||
import SwiftUI | ||
|
||
struct Fonts { | ||
|
||
static let welcomeFont: Font = UIDevice.isIPad ? Font.system(size: UIScreen.width * 0.03) : Font.system(size: UIScreen.width * 0.04) | ||
|
||
static let welcomeFontMinimized: Font = UIDevice.isIPad ? Font.system(size: UIScreen.width * 0.02) : Font.system(size: UIScreen.width * 0.03) | ||
} |
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,14 @@ | ||
// | ||
// UIDeviceExtension.swift | ||
// MLCChat | ||
// | ||
// Created by Roma iOS on 12.09.2023. | ||
// | ||
|
||
import UIKit | ||
|
||
extension UIDevice { | ||
static var isIPad: Bool { | ||
return UIDevice.current.userInterfaceIdiom == .pad | ||
} | ||
} |
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,23 @@ | ||
// | ||
// UIScreenExtension.swift | ||
// MLCChat | ||
// | ||
// Created by Roma iOS on 12.09.2023. | ||
// | ||
|
||
import UIKit | ||
|
||
extension UIScreen { | ||
|
||
static var size: CGSize { | ||
return UIScreen.main.bounds.size | ||
} | ||
|
||
static var width: CGFloat { | ||
return size.width | ||
} | ||
|
||
static var height: CGFloat { | ||
return size.height | ||
} | ||
} |
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 |
---|---|---|
|
@@ -24,6 +24,7 @@ struct MLCChatApp: App { | |
.task { | ||
appState.loadAppConfigAndModels() | ||
} | ||
.navigationViewStyle(.stack) | ||
} | ||
} | ||
} |
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.