import 'package:flutter/material.dart';

import 'package:pweb/models/wallet.dart';
import 'package:pweb/pages/payment_page/wallet/edit/buttons/buttons.dart';
import 'package:pweb/pages/payment_page/wallet/edit/fields.dart';
import 'package:pweb/utils/dimensions.dart';


class WalletEditPage extends StatelessWidget {
  final Wallet wallet;
  final VoidCallback onBack;

  const WalletEditPage({super.key, required this.wallet, required this.onBack});

  @override
  Widget build(BuildContext context) {
    final dimensions = AppDimensions();

    return Align(
      alignment: Alignment.topCenter,
      child: ConstrainedBox(
        constraints: BoxConstraints(maxWidth: dimensions.maxContentWidth),
        child: Material(
          elevation: dimensions.elevationSmall,
          color: Theme.of(context).colorScheme.onSecondary,
          borderRadius: BorderRadius.circular(dimensions.borderRadiusMedium),
          child: Padding(
            padding: EdgeInsets.all(dimensions.paddingLarge),
            child: SingleChildScrollView(
              child: Column(
                crossAxisAlignment: CrossAxisAlignment.start,
                children: [
                  IconButton(
                    icon: const Icon(Icons.arrow_back),
                    onPressed: onBack,
                  ),

                  // WalletEditHeader(),

                  WalletEditFields(),

                  const SizedBox(height: 24),

                  ButtonsWalletWidget(),

                  const SizedBox(height: 24),
                ],
              ),
            ),
          ),
        ),
      ),
    );
  }
}