markdown textarea get selection with button click handler implemented