This file is indexed.

/usr/share/javascript/yui/assets/syntax.js is in libjs-yui 2.8.2r1~squeeze-1.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

  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
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
(function() {
    var Dom = YAHOO.util.Dom,
        Event = YAHOO.util.Event,
        items = null,
        openWindow = function(node, print) {
            var n = Dom.get(node.id + '-plain'),
                code = n.value, win = null,
                h = n.offsetHeight;

            code = code.replace(/</g, '&lt;').replace(/>/g, '&gt;');
            win = window.open('', "codeview", "status=0,scrollbars=1,width=600,height=400,menubar=0,toolbar=0,directories=0"); 
            win.document.body.innerHTML = '<pre>' + code + '</pre>';

            if (print) {
                YAHOO.lang.later(1000, win, function() {
                    win.focus();
                    win.print();
                    win.focus();
                });
            }
        },
        handleClick = function(e) {
            var tar = Event.getTarget(e);
            if (tar.tagName.toLowerCase() == 'a') {
                var type = tar.innerHTML.replace(/ /g, '');
                switch (type) {
                    case 'print':
                        openWindow(tar.parentNode.parentNode, true);
                        break;
                    case 'viewplain':
                        openWindow(tar.parentNode.parentNode);
                        break;
                    case 'togglelinenumbers':
                        if (Dom.hasClass(tar.parentNode.parentNode, 'yui-syntax-highlight-linenumbers')) {
                            Dom.removeClass(tar.parentNode.parentNode, 'yui-syntax-highlight-linenumbers')
                        } else {
                            Dom.addClass(tar.parentNode.parentNode, 'yui-syntax-highlight-linenumbers')
                        }
                        break;
                    case 'copy':
                        break;
                }
            }
            Event.stopEvent(e);
        },
        init = function() {
            items = Dom.getElementsByClassName('yui-syntax-highlight');
            for (var i = 0; i < items.length; i++) {
                var header = document.createElement('div');
                header.className = 'syn-header hidden';
                header.innerHTML = '<a href="#">view plain</a> | <a href="#">print</a> | <a href="#">toggle line numbers</a>';
                Event.on(header, 'click', handleClick);
                items[i].insertBefore(header, items[i].firstChild);
                Event.on(items[i], 'mouseenter', function(e) {
                    var tar = Dom.getElementsByClassName('syn-header', 'div', Event.getTarget(e));
                    Dom.removeClass(tar, 'hidden');
                });
                Event.on(items[i], 'mouseleave', function(e) {
                    var tar = Dom.getElementsByClassName('syn-header', 'div', Event.getTarget(e));
                    Dom.addClass(tar, 'hidden');
                });
            }
        };


        var loader = new YAHOO.util.YUILoader({
            require: ["event-mouseenter"],
            base: '../../../2.x/build/',
            onSuccess: init,
            timeout: 10000
        });
        loader.insert();


})();

/*
if (YUI) {
    YUI(yuiConfig).use('node', 'event-mouseenter', 'later', function(Y) {
        var items = Y.all('.yui-syntax-highlight'),
            openWindow = function(node, print) {
                var n = Y.get('#' + node.get('id') + '-plain'),
                    code = n.get('value'), win = null,
                    h = n.get('offsetHeight');

                code = code.replace(/</g, '&lt;').replace(/>/g, '&gt;');
                win = window.open('', "codeview", "status=0,scrollbars=1,width=600,height=400,menubar=0,toolbar=0,directories=0"); 
                win.document.body.innerHTML = '<pre>' + code + '</pre>';

                if (print) {
                    Y.later(1000, win, function() {
                        win.focus();
                        win.print();
                        win.focus();
                    });
                }
            },
            handleClick = function(e) {
                if (e.target.get('tagName').toLowerCase() == 'a') {
                    var type = e.target.get('innerHTML').replace(/ /g, '');
                    switch (type) {
                        case 'print':
                            openWindow(e.target.get('parentNode.parentNode'), true);
                            break;
                        case 'viewplain':
                            openWindow(e.target.get('parentNode.parentNode'));
                            break;
                        case 'togglelinenumbers':
                            e.target.get('parentNode.parentNode').toggleClass('yui-syntax-highlight-linenumbers');
                            break;
                        case 'copy':
                            break;
                    }
                }
                e.halt();
            };



        items.each(function(i) {
            //var header = Y.Node.create('<div class="syn-header hidden"><a href="#">view plain</a> | <a href="#">print</a> | <a href="#">copy</a></div>');
            var header = Y.Node.create('<div class="syn-header hidden"><a href="#">view plain</a> | <a href="#">print</a> | <a href="#">toggle line numbers</a></div>');
            header.on('click', handleClick);
            i.insertBefore(header, i.get('firstChild'));
            i.on('mouseenter', function() {
                header.removeClass('hidden');
            });
            i.on('mouseleave', function() {
                header.addClass('hidden');
            });
        });
    });
}
*/