import 'package:flutter/material.dart';

// ignore: must_be_immutable
class TextQuestion extends StatelessWidget {
  int fieldId;
  Function fillAnswer;
  TextQuestion(this.fieldId, this.fillAnswer);

  @override
  Widget build(BuildContext context) {
    return TextFormField(
      onChanged: (value) {
        fillAnswer(this.fieldId, value.toString());
      },
    );
  }
}
