同位素过滤器 |搜索 |范围滑块 |按钮

问题描述 投票:0回答:0

我想向这个 JS 添加一个搜索字段 - (https://codepen.io/lifeonlars/pen/yaaOey) - 但脚本不起作用。问题出在哪里?这是一个功能代码示例,其中包含一个搜索 (https://codepen.io/bscherer/pen/ONYaQL) 我需要添加到我的代码中...谢谢您的建议

我添加了但没有工作:

  $('#search').on('keyup', function() {
    var searchValue = this.value.toLowerCase();
    $grid.isotope({
      filter: function() {
        var title = $(this).find('.title').text().toLowerCase();
        return title.indexOf(searchValue) > -1;
      }
    });
  });
javascript filter jquery-isotope bootstrap-slider
© www.soinside.com 2019 - 2024. All rights reserved.