Skip to content

Commit cc99912

Browse files
committed
fix: base button animation
1 parent 563b508 commit cc99912

File tree

2 files changed

+7
-6
lines changed

2 files changed

+7
-6
lines changed

BaseSwiftUI/Presentation/Component/BaseButton.swift

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,9 @@ struct BaseButton: View {
1717
Text(title)
1818
.foregroundStyle(isEnabled ? .white : Color.white.opacity(0.5))
1919
.frame(maxWidth: .infinity, maxHeight: .infinity)
20+
.transaction { transaction in
21+
transaction.animation = nil
22+
}
2023
}
2124
.foregroundStyle(.white)
2225
.background(Color(R.color.primary))

BaseSwiftUI/Presentation/Component/BaseTextField.swift

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -53,12 +53,10 @@ struct BaseTextField: View {
5353
.padding(.trailing, Spacing.small.value)
5454

5555
if !errorMessage.isEmpty {
56-
withAnimation {
57-
Text(errorMessage)
58-
.foregroundStyle(.red)
59-
.font(.footnote)
60-
.frame(maxWidth: .infinity, alignment: .leading)
61-
}
56+
Text(errorMessage)
57+
.foregroundStyle(.red)
58+
.font(.footnote)
59+
.frame(maxWidth: .infinity, alignment: .leading)
6260
}
6361
}
6462
}

0 commit comments

Comments
 (0)