From 37582c6cfa93e86605abb0e46743ab7aab2741ec Mon Sep 17 00:00:00 2001 From: Amisha Date: Wed, 1 Jan 2025 18:38:35 +0530 Subject: [PATCH] Reset code latters --- BaseStyle/BaseStyle/Extension/String+Extension.swift | 2 +- Splito/UI/Home/Groups/Add Member/JoinMemberView.swift | 6 +++--- .../UI/Home/Groups/Create Group/CreateGroupView.swift | 10 +++++----- 3 files changed, 9 insertions(+), 9 deletions(-) diff --git a/BaseStyle/BaseStyle/Extension/String+Extension.swift b/BaseStyle/BaseStyle/Extension/String+Extension.swift index cf1f64f7..51390fb8 100644 --- a/BaseStyle/BaseStyle/Extension/String+Extension.swift +++ b/BaseStyle/BaseStyle/Extension/String+Extension.swift @@ -22,7 +22,7 @@ extension String { } public func randomString(length: Int) -> String { - let letters = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789" + let letters = "ABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789" return String((0.. CODE_TOTAL_CHARACTERS { - text = String(newValue.prefix(CODE_TOTAL_CHARACTERS)) + text = String(newValue.prefix(CODE_TOTAL_CHARACTERS)).uppercased() return } // Validate input characters by allowing only alphanumeric - text = newValue.filter { $0.isLetter || $0.isNumber } + text = newValue.filter { $0.isLetter || $0.isNumber }.uppercased() if newValue.count == CODE_TOTAL_CHARACTERS { onCodeChange() isFocused.wrappedValue = false } } - .textInputAutocapitalization(.characters) .onAppear { isFocused.wrappedValue = true } diff --git a/Splito/UI/Home/Groups/Create Group/CreateGroupView.swift b/Splito/UI/Home/Groups/Create Group/CreateGroupView.swift index 87e9c1c5..2e0d1ddc 100644 --- a/Splito/UI/Home/Groups/Create Group/CreateGroupView.swift +++ b/Splito/UI/Home/Groups/Create Group/CreateGroupView.swift @@ -22,24 +22,24 @@ struct CreateGroupView: View { ScrollView { VStack(spacing: 0) { VSpacer(40) - + AddGroupImageView(showImagePickerOptions: $viewModel.showImagePickerOptions, image: viewModel.profileImage, imageUrl: viewModel.profileImageUrl, handleProfileTap: viewModel.handleProfileTap, handleActionSelection: viewModel.handleActionSelection(_:)) - + VSpacer(30) - + AddGroupNameView(groupName: $viewModel.groupName) .focused($isFocused) - + Spacer(minLength: 130) } .padding(.horizontal, 16) } .scrollIndicators(.hidden) .scrollBounceBehavior(.basedOnSize) - + PrimaryButton(text: viewModel.group != nil ? "Save" : "Create", isEnabled: viewModel.groupName.count >= 3, showLoader: viewModel.showLoader, onClick: { Task { let isSucceed = await viewModel.handleDoneAction()