WordPress.org

Plugin Directory

Changeset 1606632


Ignore:
Timestamp:
03/02/17 16:12:00 (8 months ago)
Author:
jchristopher
Message:

SearchWP Live Ajax Search 1.2.0

Location:
searchwp-live-ajax-search/trunk
Files:
6 added
4 deleted
7 edited

Legend:

Unmodified
Added
Removed
  • searchwp-live-ajax-search/trunk

    • Property svn:ignore
      •  

        old new  
        33node_modules 
        44tasks 
         5bower_components 
  • searchwp-live-ajax-search/trunk/Gruntfile.js

    r908292 r1606632  
    2222                "trailing": false, 
    2323                "undef": true, 
     24                reporterOutput: '', 
    2425                "globals": { 
    2526                    "jQuery": true, 
     
    3435        }, 
    3536 
     37        bower_concat: { 
     38            all: { 
     39                dest: 'assets/javascript/source/bower.js', 
     40                cssDest: 'assets/styles/bower.css', 
     41                exclude: [ 
     42                    'jquery' 
     43                ], 
     44                include: [ 
     45                    'spin.js' 
     46                ] 
     47            } 
     48        }, 
     49 
     50        concat: { 
     51            options: { 
     52                separator: '' 
     53            }, 
     54            dist: { 
     55                src: [ 
     56                    'assets/javascript/source/bower.js', 
     57                    'assets/javascript/source/searchwp-live-search.js' 
     58                ], 
     59                dest: 'assets/javascript/build/searchwp-live-search.js' 
     60            } 
     61        }, 
     62 
    3663        uglify: { 
    3764            dist: { 
    3865                files: { 
    39                     'assets/javascript/searchwp-live-search.min.js': [ 
    40                         'assets/javascript/source/searchwp-live-search-staged.js' 
    41                     ] 
     66                    'assets/javascript/build/searchwp-live-search.min.js': 'assets/javascript/build/searchwp-live-search.js' 
    4267                } 
    4368            } 
    44         }, 
    45  
    46         import: { 
    47             options: {}, 
    48             dist: { 
    49                 src: 'assets/javascript/source/wrapper.js', 
    50                 dest: 'assets/javascript/source/searchwp-live-search-staged.js' 
    51             }, 
    52             tasks: ['jshint','uglify'] 
    5369        }, 
    5470 
     
    5874                    '<%= jshint.all %>' 
    5975                ], 
    60                 tasks: ['import','jshint','uglify'] 
     76                tasks: [ 'jshint', 'bower_concat', 'concat', 'uglify' ] 
    6177            } 
    6278        } 
     
    6682    grunt.loadNpmTasks('grunt-import'); 
    6783    grunt.loadNpmTasks('grunt-contrib-jshint'); 
     84    grunt.loadNpmTasks('grunt-bower-concat'); 
     85    grunt.loadNpmTasks('grunt-contrib-concat'); 
    6886    grunt.loadNpmTasks('grunt-contrib-uglify'); 
    6987    grunt.loadNpmTasks('grunt-contrib-watch'); 
     
    7189    // Register tasks 
    7290    grunt.registerTask('default', [ 
    73         'import', 
    7491        'jshint', 
     92        'bower_concat', 
     93        'concat', 
    7594        'uglify', 
    7695        'watch' 
  • searchwp-live-ajax-search/trunk/assets/javascript/source/searchwp-live-search.js

    r1466381 r1606632  
    189189        maybe_search: function(e){ 
    190190            clearTimeout(this.timer); 
    191             if(this.last_string !== $.trim(e.currentTarget.value) && e.currentTarget.value.length >= this.config.input.min_chars){ 
     191            if(e.currentTarget.value.length >= this.config.input.min_chars){ 
    192192                this.timer = setTimeout( 
    193193                    $.proxy(this.search, this, e), 
     
    218218                $form = this.form_el, 
    219219                values = $form.serialize(), 
    220                 action = $form.attr('action'), 
     220                action = $form.attr('action') ? $form.attr('action') : '', 
    221221                $input = this.input_el, 
    222222                $results = this.results_el; 
  • searchwp-live-ajax-search/trunk/includes/class-form.php

    r1221563 r1606632  
    9898 
    9999        // scripts 
    100         wp_enqueue_script( 'jquery' ); 
    101         wp_register_script( 'swp-live-search-client', $this->url . '/assets/javascript/searchwp-live-search.min.js', array( 'jquery' ), $this->version, false ); 
     100        wp_enqueue_script( 'jquery' ); 
     101 
     102        /** 
     103         * If WP is in script debug, or we pass ?script_debug in a URL - set debug to true. 
     104         */ 
     105        $debug = ( defined( 'SCRIPT_DEBUG' ) && SCRIPT_DEBUG == true ) || ( isset( $_GET['script_debug'] ) ) ? true : false; 
     106 
     107        /** 
     108         * Should we load minified files? 
     109         */ 
     110        if ($debug){ 
     111            wp_register_script( 
     112                'swp-live-search-client', 
     113                $this->url . '/assets/javascript/build/searchwp-live-search.js', 
     114                array( 'jquery' ), 
     115                $this->version, 
     116                true 
     117            ); 
     118        } else { 
     119            wp_register_script( 
     120                'swp-live-search-client', 
     121                $this->url . '/assets/javascript/build/searchwp-live-search.min.js', 
     122                array( 'jquery' ), 
     123                $this->version, 
     124                true 
     125            ); 
     126        } 
    102127 
    103128        // set up our parameters 
  • searchwp-live-ajax-search/trunk/package.json

    r908292 r1606632  
    11{ 
    22  "name": "searchwp_live_search", 
    3   "version": "1.0.0", 
    4   "description": "SearchWP Live Search", 
     3  "version": "1.2.0", 
     4  "description": "SearchWP Live Ajax Search", 
    55  "main": "Gruntfile.js", 
    66  "scripts": { 
     
    1313  "dependencies": { 
    1414    "grunt": "~0.4.0", 
    15     "grunt-contrib-compass": "~0.7.2", 
    1615    "grunt-contrib-jshint": "~0.10.0", 
    1716    "grunt-contrib-uglify": "~0.4.0", 
     
    1918  }, 
    2019  "devDependencies": { 
    21     "grunt-import": "^0.1.7", 
    22     "grunt-includes": "^0.4.4" 
     20    "grunt-bower-concat": "^1.0.0", 
     21    "grunt-contrib-concat": "^1.0.0" 
    2322  } 
    2423} 
  • searchwp-live-ajax-search/trunk/readme.txt

    r1466381 r1606632  
    33Tags: search, live, ajax 
    44Requires at least: 3.9 
    5 Tested up to: 4.6 
    6 Stable tag: 1.1.8 
     5Tested up to: 4.7.2 
     6Stable tag: 1.2.0 
    77License: GPLv2 or later 
    88License URI: http://www.gnu.org/licenses/gpl-2.0.html 
     
    7070== Screenshots == 
    7171 
    72 1. SearchWP Live Ajax Search automagically working in Twenty Fourteen instantly after activating 
     721. SearchWP Live Ajax Search automatically working in Twenty Fourteen instantly after activating 
    73732. Search results with default 'theme' (can be completely (completely) customized) 
    74743. SearchWP Live Ajax Search Widget 
     
    7676 
    7777== Changelog == 
     78 
     79= 1.2.0 = 
     80* Reworked build process to be more straightforward 
     81* Support script debugging (props mgratch) 
     82* Remove form action requirement to better integrate with other code (props mgratch) 
     83* Fixed an issue that prevented search from firing when re-entered too fast (props pierrestoffe) 
    7884 
    7985= 1.1.8 = 
  • searchwp-live-ajax-search/trunk/searchwp-live-ajax-search.php

    r1466381 r1606632  
    44Plugin URI: https://searchwp.com/ 
    55Description: Enhance your search forms with live search, powered by SearchWP (if installed) 
    6 Version: 1.1.8 
     6Version: 1.2.0 
    77Author: Jonathan Christopher 
    88Author URI: https://searchwp.com/ 
    99Text Domain: swplas 
    1010 
    11 Copyright 2014-2016 Jonathan Christopher 
     11Copyright 2014-2017 Jonathan Christopher 
    1212 
    1313This program is free software; you can redistribute it and/or 
     
    4444    public $dir; 
    4545    public $url; 
    46     public $version = '1.1.8'; 
     46    public $version = '1.2.0'; 
    4747    public $results = array(); 
    4848 
Note: See TracChangeset for help on using the changeset viewer.