cursorWidget method

Widget cursorWidget({
  1. Color? cursorColor,
  2. double? cursorWidth,
  3. int? index,
})

Implementation

Widget cursorWidget({Color? cursorColor, double? cursorWidth, int? index}) {
  return Container(
    padding: pinsInputed[index ?? 0].isNotEmpty ? const EdgeInsets.only(left: 15) : EdgeInsets.zero,
    child: FadeTransition(
      opacity: _cursorAnimation,
      child: CustomPaint(
        size: const Size(0, 25),
        painter: CursorPainter(
          cursorColor: cursorColor,
          cursorWidth: cursorWidth,
        ),
      ),
    ),
  );
}