Page Menu
Home
Musing Studio
Search
Configure Global Search
Log In
Files
F10387188
SettingsView.swift
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
1 KB
Subscribers
None
SettingsView.swift
View Options
import
SwiftUI
struct
MacAccountView
:
View
{
@
ObservedObject
var
preferences
:
PreferencesModel
@
ObservedObject
var
account
:
AccountModel
@
State
var
selectedView
=
0
var
body
:
some
View
{
TabView
(
selection
:
$
selectedView
)
{
Form
{
Section
(
header
:
Text
(
"Login Details"
))
{
AccountView
(
account
:
account
)
}
}
.
tabItem
{
Image
(
systemName
:
"person.crop.circle"
)
Text
(
"Account"
)
}
.
tag
(
0
)
VStack
{
PreferencesView
(
preferences
:
preferences
)
Spacer
()
}
.
tabItem
{
Image
(
systemName
:
"gear"
)
Text
(
"Preferences"
)
}
.
tag
(
1
)
}
}
}
struct
SettingsView_AccountTabPreviews
:
PreviewProvider
{
static
var
previews
:
some
View
{
MacAccountView
(
preferences
:
PreferencesModel
(),
account
:
AccountModel
(),
selectedView
:
0
)
}
}
struct
SettingsView_PreferencesTabPreviews
:
PreviewProvider
{
static
var
previews
:
some
View
{
MacAccountView
(
preferences
:
PreferencesModel
(),
account
:
AccountModel
(),
selectedView
:
1
)
}
}
File Metadata
Details
Attached
Mime Type
text/x-c
Expires
Mon, Nov 25, 1:53 AM (1 d, 10 h)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
3106499
Attached To
rWFSUI WriteFreely SwiftUI
Event Timeline
Log In to Comment