Added AccessibilityIdentifiers helper struct with identifiers for all major UI elements across the app. Applied identifiers throughout authentication, navigation, forms, and feature screens to enable reliable UI testing. Changes: - Added Helpers/AccessibilityIdentifiers.swift with centralized ID definitions - LoginView: Added identifiers for username, password, login button fields - RegisterView: Added identifiers for registration form fields - MainTabView: Added identifiers for all tab bar items - ProfileTabView: Added identifiers for logout and settings buttons - ResidencesListView: Added identifier for add button - Task views: Added identifiers for add, save, and form fields - Document forms: Added identifiers for form fields and buttons Identifiers follow naming pattern: [Feature].[Element] Example: AccessibilityIdentifiers.Authentication.loginButton This enables UI tests to reliably locate elements using: app.buttons[AccessibilityIdentifiers.Authentication.loginButton] 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
18 lines
460 B
Swift
18 lines
460 B
Swift
import SwiftUI
|
|
import ComposeApp
|
|
|
|
/// Wrapper view for adding a new task
|
|
/// This is now just a convenience wrapper around TaskFormView in "add" mode
|
|
struct AddTaskView: View {
|
|
let residenceId: Int32
|
|
@Binding var isPresented: Bool
|
|
|
|
var body: some View {
|
|
TaskFormView(residenceId: residenceId, residences: nil, existingTask: nil, isPresented: $isPresented)
|
|
}
|
|
}
|
|
|
|
#Preview {
|
|
AddTaskView(residenceId: 1, isPresented: .constant(true))
|
|
}
|