mirror of
https://github.com/Dimillian/IceCubesApp.git
synced 2024-11-26 18:21:00 +00:00
Don't erase alt text on app switch Fix #1419
This commit is contained in:
parent
4168c64d20
commit
67d1dede04
1 changed files with 7 additions and 2 deletions
|
@ -16,6 +16,8 @@ struct StatusEditorMediaEditView: View {
|
||||||
|
|
||||||
@State private var isUpdating: Bool = false
|
@State private var isUpdating: Bool = false
|
||||||
|
|
||||||
|
@State private var didAppear: Bool = false
|
||||||
|
|
||||||
var body: some View {
|
var body: some View {
|
||||||
NavigationStack {
|
NavigationStack {
|
||||||
Form {
|
Form {
|
||||||
|
@ -51,8 +53,11 @@ struct StatusEditorMediaEditView: View {
|
||||||
.scrollContentBackground(.hidden)
|
.scrollContentBackground(.hidden)
|
||||||
.background(theme.secondaryBackgroundColor)
|
.background(theme.secondaryBackgroundColor)
|
||||||
.onAppear {
|
.onAppear {
|
||||||
|
if !didAppear {
|
||||||
imageDescription = container.mediaAttachment?.description ?? ""
|
imageDescription = container.mediaAttachment?.description ?? ""
|
||||||
isFieldFocused = true
|
isFieldFocused = true
|
||||||
|
didAppear = true
|
||||||
|
}
|
||||||
}
|
}
|
||||||
.navigationTitle("status.editor.media.edit-image")
|
.navigationTitle("status.editor.media.edit-image")
|
||||||
.navigationBarTitleDisplayMode(.inline)
|
.navigationBarTitleDisplayMode(.inline)
|
||||||
|
|
Loading…
Reference in a new issue