Blame view

bower_components/select2/docs/_includes/examples/hide-search.html 653 Bytes
f6e211e4   Administrator   finish work part 1
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
  <section>
  
    <h1 id="hide-search">Hiding the search box</h1>
  
    <p>
      Select2 allows you to hide the search box depending on the number of
      options which are displayed. In this example, we use the value
      <code>Infinity</code> to tell Select2 to never display the search box.
    </p>
  
    <div class="s2-example">
      <p>
        <select class="js-example-basic-hide-search js-states form-control"></select>
      </p>
    </div>
  
    <pre data-fill-from=".js-code-hide-search"></pre>
  
  <script type="text/x-example-code" class="js-code-hide-search">
  $(".js-example-basic-hide-search").select2({
    minimumResultsForSearch: Infinity
  });
  </script>
  
  </section>