MessageBox Close reFocuses to the last textarea

Description

When i hit close of a Message Box program refocusses on last created textarea on screen

What MCU/Processor/Board and compiler are you using?

esp32

What LVGL version are you using?

8.3

What do you want to achieve?

On LV_EVENT_READY of a textarea i have set a validation of the value and if it is of range i show a message box and reset the value. User on message box just hits close. On close button screen refocuses on the last textarea created on screen irrelevant of the textarea that LV_EVENT_READY was initiated

What have you tried so far?

On generic textarea callback i have a switch to check events. ON lv_event_ready i run a functions that return boolean base on value of the textarea. It runs only on textareas that the keyboard is numeric.
User can only hit close button. On close the rest of the lv_event_ready runs and for some reason the keyboard is shown again and the another textarea is refocused. This textarea is always the same and it is the last created on screen.
If i remove the functionallity of the messagebox the lv_event_ready works normally.

The same happens with the lv_event_cancel which i use to navigate with keyboard button between objects like tab on keyboard.

Code to reproduce

		case LV_EVENT_READY:
			{
				LV_LOG_USER("LV_EVENT_READY");
				LV_LOG_USER("state in ready: %s",str_get_obj_state(ta));//custom function to identify the states of the textarea
				if(!str_validate_input(mode, ta)){//validate gives true if everything is ok
					lv_textarea_set_text(ta, "30");//reseting the textarea value
				}
				lv_obj_clear_state(ta, LV_STATE_FOCUSED);
				lv_obj_add_flag(keyboards, LV_OBJ_FLAG_HIDDEN);
				lv_obj_clear_flag(stringerConf.mp_obj.chart, LV_OBJ_FLAG_HIDDEN);
				lv_indev_reset(NULL, ta);
				if(yTranslate!=0){
					lv_obj_set_style_translate_y(lv_obj_get_parent(ta), 0, 0);
					yTranslate=0;
				}
			}
			break;
		case LV_EVENT_CANCEL:
			{
				str_validate_input(mode, ta);
				lv_group_focus_next(formGroup);
				LV_LOG_USER("LV_EVENT_CANCEL");
				LV_LOG_USER("state in cancel: %s",str_get_obj_state(ta));
			}
			break;


bool str_validate_input(lv_keyboard_mode_t kbMode,lv_obj_t* textArea){


	switch (kbMode) {
		case LV_KEYBOARD_MODE_NUMBER:
			{
				float value = strtof(lv_textarea_get_text(textArea), NULL);
				if(value > 30){
					lv_obj_t* errorMsg = lv_msgbox_create(NULL, "Incorrect Value.", "Value cannot be bigger than maximum of 30 Kg and will be set to Max", NULL, true);
					lv_obj_center(errorMsg);
					lv_textarea_set_text(textArea, "30");
					return false;
				}
			}
			break;
		default:
			break;
	}
	return true;
}