Closed JEuler closed 1 year ago
That's not right, because if you have more than one actions, search icon appears two times.
The code it would be like this when putActionsOnRight is enabled:
return IconTheme(
data: iconTheme,
child: IconButton(
icon: const Icon(Icons.search),
iconSize: iconTheme.size ?? 24,
onPressed: () {
_controller.forward();
_focusNode.requestFocus();
if (widget.openOverlayOnSearch) {
openOverlay();
}
},
tooltip: MaterialLocalizations.of(context).searchFieldLabel
)
);
}
return IconTheme(
data: iconTheme,
child: widget.actions[index - 1]
);```
I would be very grateful if you update it, thank you!
I have this code in my app with 3 actions and it is working like expected. 😕
Could you recheck?
Hello @JEuler,
First of all, I'm sorry for only being able to respond to your issue after a long time. Thank you for you valuable contribution. Just going to reduce the duplicated code and then update the package.
Have a nice day
Added flag (with kind of duplicated bad code, but was in hurry). :) Thank you for the nice library.