├── screenshots └── highlight.png ├── bower.json ├── .jshintrc ├── .jscs.json ├── package.json ├── LICENSE ├── Gruntfile.js ├── README.md ├── README.ru.md ├── dist ├── jquery.lookingfor.min.js ├── jquery.lookingfor.min.map └── jquery.lookingfor.js ├── html ├── simple.html ├── highlight.html └── data │ └── countries.csv └── src └── jquery.lookingfor.js /screenshots/highlight.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/albburtsev/jquery.lookingfor/HEAD/screenshots/highlight.png -------------------------------------------------------------------------------- /bower.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "jquery.lookingfor", 3 | "version": "0.0.8", 4 | "main": ["jquery.lookingfor.js"], 5 | "ignore": [ 6 | "Gruntfile.js", 7 | "package.json", 8 | ".jscs.json", 9 | ".jshintrc", 10 | "screenshots", 11 | "html" 12 | ], 13 | "dependencies": { 14 | "jquery": ">=1.7" 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /.jshintrc: -------------------------------------------------------------------------------- 1 | 2 | { 3 | "bitwise": true, 4 | "browser": true, 5 | "eqeqeq": true, 6 | "camelcase": true, 7 | "curly": true, 8 | "debug": true, 9 | "forin": true, 10 | "freeze": true, 11 | "immed": true, 12 | "latedef": true, 13 | "maxdepth": 3, 14 | "maxparams": 3, 15 | "newcap": true, 16 | "noarg": true, 17 | "noempty": true, 18 | "nonbsp": true, 19 | "quotmark": "single", 20 | "undef": true, 21 | "unused": true, 22 | "predef": [ 23 | "define", 24 | "jQuery" 25 | ] 26 | } -------------------------------------------------------------------------------- /.jscs.json: -------------------------------------------------------------------------------- 1 | 2 | { 3 | "requireCurlyBraces": ["for", "while", "do", "if", "else"], 4 | "requireSpaceAfterKeywords": ["if", "for", "while", "do", "switch", "return"], 5 | "disallowSpacesInsideArrayBrackets": true, 6 | "requireSpacesInsideObjectBrackets": "all", 7 | "disallowQuotedKeysInObjects": true, 8 | "disallowSpaceAfterObjectKeys": true, 9 | "disallowLeftStickedOperators": ["?", "+", "-", "/", "*", "=", "==", "===", "!=", "!==", ">", ">=", "<", "<="], 10 | "requireRightStickedOperators": ["!"], 11 | "disallowRightStickedOperators": ["?", "+", "/", "*", ":", "=", "==", "===", "!=", "!==", ">", ">=", "<", "<="], 12 | "requireLeftStickedOperators": [","], 13 | "disallowKeywords": ["with", "eval"], 14 | "validateJSDoc": { 15 | "checkParamNames": true, 16 | "checkRedundantParams": true, 17 | "requireParamTypes": true 18 | } 19 | } -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "jquery.lookingfor", 3 | "version": "0.0.8", 4 | "description": "Fast search as you type jQuery-plugin", 5 | "repository": { 6 | "type": "git", 7 | "url": "git://github.com/albburtsev/jquery.lookingfor.git" 8 | }, 9 | "keywords": [ 10 | "jquery", 11 | "plugin", 12 | "search", 13 | "highlight", 14 | "client search", 15 | "page search" 16 | ], 17 | "author": { 18 | "name": "Alexander Burtsev", 19 | "url": "https://github.com/albburtsev" 20 | }, 21 | "license": "MIT", 22 | "bugs": { 23 | "url": "https://github.com/albburtsev/jquery.lookingfor/issues" 24 | }, 25 | "homepage": "https://github.com/albburtsev/jquery.lookingfor", 26 | "devDependencies": { 27 | "grunt": "^0.4.4", 28 | "grunt-contrib-copy": "^0.8.0", 29 | "grunt-contrib-jshint": "^0.10.0", 30 | "grunt-contrib-uglify": "^0.4.0", 31 | "grunt-contrib-watch": "^0.6.1", 32 | "grunt-jscs-checker": "^0.4.1", 33 | "matchdep": "^0.3.0" 34 | } 35 | } 36 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | The MIT License (MIT) 2 | 3 | Copyright (c) 2014 Alexander Burtsev 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy of 6 | this software and associated documentation files (the "Software"), to deal in 7 | the Software without restriction, including without limitation the rights to 8 | use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of 9 | the Software, and to permit persons to whom the Software is furnished to do so, 10 | subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 17 | FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 18 | COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 19 | IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 20 | CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 21 | -------------------------------------------------------------------------------- /Gruntfile.js: -------------------------------------------------------------------------------- 1 | module.exports = function(grunt) { 2 | 'use strict'; 3 | 4 | require('matchdep') 5 | .filterDev('grunt-*') 6 | .forEach(grunt.loadNpmTasks); 7 | 8 | grunt.initConfig({ 9 | jsSource: 'src/*.js', 10 | jsDist: 'dist/', 11 | banner: 12 | '/**\n' + 13 | ' * jquery.lookingfor — fast search as you type\n' + 14 | ' * @author Alexander Burtsev, http://burtsev.me, 2014—<%= grunt.template.today("yyyy") %>\n' + 15 | ' * @license MIT\n' + 16 | ' */\n', 17 | 18 | jshint: { 19 | options: { 20 | jshintrc: '.jshintrc' 21 | }, 22 | app: ['<%= jsSource %>'] 23 | }, 24 | 25 | jscs: { 26 | options: { 27 | config: '.jscs.json' 28 | }, 29 | app: ['<%= jsSource %>'] 30 | }, 31 | 32 | copy: { 33 | options: { 34 | process: function (content, srcpath) { 35 | return grunt.config.get('banner') + content; 36 | } 37 | }, 38 | source: { 39 | files: [{ 40 | expand: true, 41 | cwd: 'src/', 42 | src: ['**'], 43 | dest: 'dist/' 44 | }] 45 | } 46 | }, 47 | 48 | uglify: { 49 | options: { 50 | banner: '<%= banner %>', 51 | sourceMap: true 52 | }, 53 | lookingfor: { 54 | files: { 55 | '<%= jsDist %>jquery.lookingfor.min.js': ['<%= jsSource %>'] 56 | } 57 | } 58 | }, 59 | 60 | watch: { 61 | lookingfor: { 62 | files: ['<%= jsSource %>'], 63 | tasks: ['jshint', 'jscs', 'uglify'] 64 | } 65 | } 66 | }); 67 | 68 | grunt.registerTask('default', ['jshint', 'jscs', 'copy', 'uglify', 'watch']); 69 | }; 70 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | jquery.lookingfor 2 | ================= 3 | 4 |  5 | 6 | Fast search as you type jQuery plugin. 7 | 8 | It's very small (minified — 2.5kb, gzipped — 1.2kb), very fast and supports old browsers (IE6+). 9 | 10 | __jquery.lookingfor__ plugin searches text in list items (```