JSFiddle - React, Tailwind, and code Playground

HTML

<div id="selectable-text">This text supports the magnifying glass.</div>

<div id="some-html-id">
  On the red area the magnifying glass should NOT appear. <br>
  But on the white!
</div>

CSS

#selectable-text {
  text-align: center; 
  padding: 10px;
}

#some-html-id {
  background-color: red;
  padding: 100px;
  text-align: center;
  width: 400px;
  margin: 10%;
  color: white;
  
  -webkit-user-select: none;
	-moz-user-select: none;
	user-select: none;
}

JavaScript

/* disable magnifying glass on specific html element */
var htmlElement = document.getElementById( 'some-html-id' );


htmlElement.addEventListener('touchstart', function( event ) { 
      event.preventDefault();
}, false);