|
|
@@ -3,7 +3,6 @@ import SwiftUI
|
|
|
struct CommentWriterView: View {
|
|
|
@Environment(\.requirePremiumAccess) private var requirePremiumAccess
|
|
|
@Bindable var viewModel: CommentWriterViewModel
|
|
|
- let onOpenInReddit: (URL) -> Void
|
|
|
|
|
|
var body: some View {
|
|
|
VStack(spacing: 0) {
|
|
|
@@ -107,15 +106,6 @@ struct CommentWriterView: View {
|
|
|
}
|
|
|
.buttonStyle(CommentSecondaryButtonStyle())
|
|
|
|
|
|
- Button {
|
|
|
- viewModel.openInReddit(openInApp: onOpenInReddit)
|
|
|
- } label: {
|
|
|
- Label("Open Thread", systemImage: "arrow.up.right.square")
|
|
|
- .font(.system(size: 11, weight: .medium))
|
|
|
- }
|
|
|
- .buttonStyle(CommentSecondaryButtonStyle())
|
|
|
- .disabled(viewModel.draft.postURL.trimmingCharacters(in: .whitespaces).isEmpty)
|
|
|
-
|
|
|
Button {
|
|
|
viewModel.copyToClipboard()
|
|
|
} label: {
|
|
|
@@ -506,6 +496,6 @@ struct CommentWriterView: View {
|
|
|
}
|
|
|
|
|
|
#Preview {
|
|
|
- CommentWriterView(viewModel: CommentWriterViewModel()) { _ in }
|
|
|
+ CommentWriterView(viewModel: CommentWriterViewModel())
|
|
|
.frame(width: 880, height: 720)
|
|
|
}
|