boolean-uk / team-dev-frontend-client

1 stars 11 forks source link

Create App.css class to avoid selection #185

Closed lucianosimoni closed 1 year ago

lucianosimoni commented 1 year ago

Some components are not supposed to be selectable (Like an SVG icon). So having a global class to put in these elements is a way to avoid such things.

Code to add into App.css

.noselect {
  -webkit-touch-callout: none; /* iOS Safari */
    -webkit-user-select: none; /* Safari */
     -khtml-user-select: none; /* Konqueror HTML */
       -moz-user-select: none; /* Old versions of Firefox */
        -ms-user-select: none; /* Internet Explorer/Edge */
            user-select: none; /* Non-prefixed version, currently
                                  supported by Chrome, Edge, Opera and Firefox */
}

In order to use this class, just add it to the className of the element you don't want to be selected.

Auenc commented 1 year ago

Looks great!