I am having the same issue and I have a s7 edge. At first I thought it was my screen protector. I took it off and yet it was still not working. Then I uninstalled the keyboard app I had downloaded and still nothing. Then I cleared catche and still had the same problem. The only thing that fixes it is turning off phone but then a couple hours later the problem persists. I did a hard factory reset of my phone and it worked fine for 3 days and here I am again with the same issue.