~mfisch/yelp-xsl/update-to-3.8.1

« back to all changes in this revision

Viewing changes to js/jquery.syntax.brush.apache.js

  • Committer: Package Import Robot
  • Author(s): Michael Biebl
  • Date: 2012-03-17 15:12:22 UTC
  • mfrom: (1.1.16) (11.1.3 sid)
  • Revision ID: package-import@ubuntu.com-20120317151222-pnzcgh4actzfkwdb
Tags: 3.3.3-1
New upstream development release.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
// brush: "apache" aliases: []
2
2
 
3
 
//      This file is part of the "jQuery.Syntax" project, and is licensed under the GNU AGPLv3.
4
 
//      Copyright 2010 Samuel Williams. All rights reserved.
 
3
//      This file is part of the "jQuery.Syntax" project, and is distributed under the MIT License.
 
4
//      Copyright (c) 2011 Samuel G. D. Williams. <http://www.oriontransfer.co.nz>
5
5
//      See <jquery.syntax.js> for licensing details.
6
6
 
7
7
Syntax.register('apache', function(brush) {
8
8
        brush.push({
9
 
                pattern: /<(\w+).*?>/gi,
10
 
                matches: Syntax.extractMatches({
 
9
                pattern: /(<(\w+).*?>)/gi,
 
10
                matches: Syntax.extractMatches(
 
11
                {
11
12
                        klass: 'tag',
12
 
                        allow: ['attribute'],
 
13
                        allow: ['attribute', 'tag-name', 'string']
 
14
                },
 
15
                {
 
16
                        klass: 'tag-name',
13
17
                        process: Syntax.lib.webLinkProcess("site:http://httpd.apache.org/docs/trunk/ directive", true)
14
18
                })
15
19
        });
16
20
 
17
21
        brush.push({
18
 
                pattern: /<\/(\w+).*?>/gi,
19
 
                matches: Syntax.extractMatches({klass: 'tag', allow: ['attribute']})
 
22
                pattern: /(<\/(\w+).*?>)/gi,
 
23
                matches: Syntax.extractMatches({klass: 'tag', allow: ['tag-name']}, {klass: 'tag-name'})
20
24
        });
21
25
 
22
26
        brush.push({