41 lines
1.1 KiB
Dart
41 lines
1.1 KiB
Dart
import 'package:flutter/material.dart';
|
|
import 'package:rkm_educa_prof_app/componentes/text_custom.dart';
|
|
|
|
import '../modelos/modelo_disciplina.dart';
|
|
class DropdownDisciplina extends StatelessWidget {
|
|
String titulo;
|
|
ModeloDisciplina? seleciona;
|
|
void Function(ModeloDisciplina?)? onChanged;
|
|
List<DropdownMenuItem<ModeloDisciplina>> listDropDown;
|
|
double hightLine;
|
|
|
|
DropdownDisciplina({
|
|
required this.titulo,
|
|
required this.seleciona,
|
|
required this.onChanged,
|
|
required this.listDropDown,
|
|
required this.hightLine,
|
|
});
|
|
|
|
@override
|
|
Widget build(BuildContext context) {
|
|
return Container(
|
|
height: hightLine,
|
|
child: Row(
|
|
children: [
|
|
TextCustom(text: titulo,fontWeight: FontWeight.bold),
|
|
SizedBox(width: 10,),
|
|
DropdownButtonHideUnderline(
|
|
child: DropdownButton<ModeloDisciplina>(
|
|
hint: TextCustom(text: 'SELECIONE',size: 12.0,),
|
|
value: seleciona,
|
|
items: listDropDown,
|
|
onChanged: onChanged,
|
|
),
|
|
),
|
|
],
|
|
),
|
|
);
|
|
}
|
|
}
|