// Generated by CoffeeScript 1.10.0 (function() { var cb, container, indexOf = [].indexOf || function(item) { for (var i = 0, l = this.length; i < l; i++) { if (i in this && this[i] === item) return i; } return -1; }; container = d3.select('#container'); cb = new Clipboard('.fa-clipboard'); d3.select('#header button').on('click', function() { var found, str; str = d3.select('#header input').node().value; d3.select('#header input').node().value = ''; if (window.find) { found = window.find(str); } else { alert("Your browser does not support this function!"); } return d3.select('#header input').node().value = str; }); d3.json('data.json', function(error, data) { var id, items, list, prefix; prefix = d3.keys(data['@context'])[0]; /* FILTERING: only dummy instances are kept */ list = data['@graph'].filter(function(d) { return d3.keys(d).indexOf(prefix + ":definition") > 0 && indexOf.call(d['@type'], "owl:NamedIndividual") >= 0; }); list = list.sort(function(a, b) { return d3.ascending(a['@id'], b['@id']); }); /* VISUALIZATION */ items = container.selectAll('.item').data(list); items.enter().append('div').attr({ "class": 'item' }); items.html(function(d) { var name; name = d['@id'].split(':')[1]; return "