fix: widthFactor 1 for urlfield

This commit is contained in:
DenserMeerkat
2024-07-11 23:50:01 +05:30
parent ec9d76868c
commit 5d28b5c4f9
2 changed files with 4 additions and 1 deletions

View File

@ -13,6 +13,7 @@ class EnvironmentTriggerField extends StatefulWidget {
this.onFieldSubmitted,
this.style,
this.decoration,
this.optionsWidthFactor,
});
final String keyId;
@ -21,6 +22,7 @@ class EnvironmentTriggerField extends StatefulWidget {
final void Function(String)? onFieldSubmitted;
final TextStyle? style;
final InputDecoration? decoration;
final double? optionsWidthFactor;
@override
State<EnvironmentTriggerField> createState() =>
@ -62,7 +64,7 @@ class _EnvironmentTriggerFieldState extends State<EnvironmentTriggerField> {
key: Key(widget.keyId),
textEditingController: controller,
focusNode: focusNode,
optionsWidthFactor: null,
optionsWidthFactor: widget.optionsWidthFactor,
autocompleteTriggers: [
AutocompleteTrigger(
trigger: '{',

View File

@ -33,6 +33,7 @@ class EnvURLField extends StatelessWidget {
),
onChanged: onChanged,
onFieldSubmitted: onFieldSubmitted,
optionsWidthFactor: 1,
);
}
}