get a minus "-" symbol inside checkbox using html and css only
I tried using
document.getElementsByTagName("input")[0].indeterminate = true;
but requirement is using html and css only
get a minus "-" symbol inside checkbox using html and css only
I tried using
document.getElementsByTagName("input")[0].indeterminate = true;
but requirement is using html and css only
 
    
     
    
    It sounds like you want a label posing like a checkbox, with a minus symbol inside. Like this:
input {
  display: none
}
label {
  padding: 0 6px;
  border: 1px solid #eee
}
input:checked+label {
  background: #000;
  color: #fff
}<div>
  <input type="checkbox" id="box">
  <label for="box">-</label>
</div>