Small Knock adjustments (#3568)

* small adjustments

* autocorrection disabled
This commit is contained in:
Mauro
2024-11-28 18:02:07 +01:00
committed by GitHub
parent 000073c7a0
commit d48fb64468
3 changed files with 4 additions and 4 deletions
@@ -92,7 +92,7 @@ class CreateRoomViewModel: CreateRoomViewModelType, CreateRoomViewModelProtocol
case .removeImage: case .removeImage:
actionsSubject.send(.removeImage) actionsSubject.send(.removeImage)
case .updateAliasLocalPart(let aliasLocalPart): case .updateAliasLocalPart(let aliasLocalPart):
state.aliasLocalPart = aliasLocalPart state.aliasLocalPart = aliasLocalPart.lowercased()
// If this has been called this means that the user wants a custom address not necessarily reflecting the name // If this has been called this means that the user wants a custom address not necessarily reflecting the name
// So we disable the two from syncing. // So we disable the two from syncing.
syncNameAndAlias = false syncNameAndAlias = false
@@ -195,8 +195,8 @@ struct CreateRoomScreen: View {
.foregroundStyle(.compound.textSecondary) .foregroundStyle(.compound.textSecondary)
TextField("", text: aliasBinding) TextField("", text: aliasBinding)
.autocapitalization(.none) .textInputAutocapitalization(.never)
.textCase(.lowercase) .autocorrectionDisabled()
.tint(.compound.iconAccentTertiary) .tint(.compound.iconAccentTertiary)
.font(.compound.bodyLG) .font(.compound.bodyLG)
.foregroundStyle(.compound.textPrimary) .foregroundStyle(.compound.textPrimary)
@@ -110,7 +110,7 @@ struct JoinRoomScreen: View {
HStack(spacing: 0) { HStack(spacing: 0) {
TextField("", text: $context.knockMessage, axis: .vertical) TextField("", text: $context.knockMessage, axis: .vertical)
.onChange(of: context.knockMessage) { _, newValue in .onChange(of: context.knockMessage) { _, newValue in
context.knockMessage = String(newValue.prefix(1000)) context.knockMessage = String(newValue.prefix(500))
} }
.lineLimit(4, reservesSpace: true) .lineLimit(4, reservesSpace: true)
.font(.compound.bodyMD) .font(.compound.bodyMD)