changeKeyboardHeight method

dynamic changeKeyboardHeight(
  1. double height
)

Implementation

changeKeyboardHeight(double height) {
  webviewController?.scrollTo(x: 0, y: 0);
  queueBridge = height;
  Map params = {
    "UIKeyboardFrameEndUserInfoKey": {
      "width": MediaQuery.of(context).size.width,
      "height": height,
      "x": 0,
      "y": MediaQuery.of(context).size.height - height,
    },
    "UIKeyboardAnimationDurationUserInfoKey": 0.25,
    "isShow": height > 0 ? 1 : 0,
  };
  webviewController?.evaluateJavascript(
    source:
        "window.${getRandomCharacter()}('${getRandomString()}kc',${jsonEncode(params)})",
  );
}