Skip to content

Commit

Permalink
chore: fix typo Conten -> Content
Browse files Browse the repository at this point in the history
  • Loading branch information
liweijie0812 committed Jul 5, 2024
1 parent 5cfff36 commit f81f04b
Showing 1 changed file with 8 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -80,9 +80,9 @@ class TDDropdownItem<T> extends StatefulWidget {

static const double operateHeight = 73;

double? get minContenHeight =>
double? get minContentHeight =>
multiple == true ? (minHeight != null ? minHeight! + TDDropdownItem.operateHeight : null) : minHeight;
double? get maxContenHeight =>
double? get maxContentHeight =>
multiple == true ? (maxHeight != null ? maxHeight! + TDDropdownItem.operateHeight : null) : maxHeight;

@override
Expand Down Expand Up @@ -117,15 +117,15 @@ class _TDDropdownItemState extends State<TDDropdownItem> {
Widget _getCheckboxList() {
var paddingNum = TDTheme.of(context).spacer16;
var groupCunck = _groupChunkOptions();
var maxContentHeight = widget.maxContenHeight != null
? widget.maxContenHeight!
var maxContentHeight = widget.maxContentHeight != null
? widget.maxContentHeight!
: directionListenable.value == TDDropdownMenuDirection.auto
? double.infinity
: max<double>(popupState.maxContentHeight - TDDropdownItem.operateHeight, 0);
return Column(
children: [
ConstrainedBox(
constraints: BoxConstraints(minHeight: widget.minContenHeight ?? 0.0, maxHeight: maxContentHeight),
constraints: BoxConstraints(minHeight: widget.minContentHeight ?? 0.0, maxHeight: maxContentHeight),
child: SingleChildScrollView(
child: Column(
children: List.generate(groupCunck.length, (index) {
Expand Down Expand Up @@ -197,11 +197,11 @@ class _TDDropdownItemState extends State<TDDropdownItem> {
),
),
);
return widget.minContenHeight != null || widget.maxContenHeight != null
return widget.minContentHeight != null || widget.maxContentHeight != null
? ConstrainedBox(
constraints: BoxConstraints(
minHeight: widget.minContenHeight ?? 0.0, maxHeight: widget.maxContenHeight ?? double.infinity),
child: widget.maxContenHeight != null ? SingleChildScrollView(child: radios) : radios,
minHeight: widget.minContentHeight ?? 0.0, maxHeight: widget.maxContentHeight ?? double.infinity),
child: widget.maxContentHeight != null ? SingleChildScrollView(child: radios) : radios,
)
: radios;
}
Expand Down

0 comments on commit f81f04b

Please sign in to comment.