diff --git a/.htaccess b/.htaccess index 8e65ff5..d54bf5b 100644 --- a/.htaccess +++ b/.htaccess @@ -2,11 +2,18 @@ RewriteEngine On RewriteRule "^2018/data-flaneur$" "index.html" RewriteRule "^2018/digital-cultures$" "index.html" +RewriteRule "^2020/acts-of-collection-and-omission$" "index.html" RewriteRule "^article/choose-how-you-feel-you-have-seven-options$" "index.html" RewriteRule "^assets/video/guerilla_project.mp4$" "index.html" +RewriteRule "^choose-how-you-feel-you-have-seven-options$" "index.html" +RewriteRule "^degree/avm$" "index.html" +RewriteRule "^degree/cddc$" "index.html" +RewriteRule "^degree/mechanical-engineering$" "index.html" +RewriteRule "^degree/media-design$" "index.html" RewriteRule "^emotionhero$" "index.html" RewriteRule "^event/2018/yama-ichi$" "index.html" RewriteRule "^event/2019/ccu-presentation$" "index.html" +RewriteRule "^event/cqrrelations$" "index.html" RewriteRule "^event/creativity-and-cognition$" "index.html" RewriteRule "^exercises-in-overfitting$" "index.html" RewriteRule "^exercises-in-overfitting/image/1$" "index.html" @@ -43,6 +50,7 @@ RewriteRule "^mvp3$" "index.html" RewriteRule "^mvp3/image/1$" "index.html" RewriteRule "^mvps$" "index.html" RewriteRule "^organisation/ccu$" "index.html" +RewriteRule "^organisation/constant$" "index.html" RewriteRule "^organisation/nsvp$" "index.html" RewriteRule "^organisation/setup$" "index.html" RewriteRule "^organisation/v2_$" "index.html" @@ -53,9 +61,11 @@ RewriteRule "^person/joseph-huot$" "index.html" RewriteRule "^person/merijn-van-moll$" "index.html" RewriteRule "^person/mikel-folgerts$" "index.html" RewriteRule "^person/ward-goes$" "index.html" +RewriteRule "^pillow-talk$" "index.html" RewriteRule "^place/in4art$" "index.html" RewriteRule "^place/q21$" "index.html" RewriteRule "^plottingdata$" "index.html" +RewriteRule "^residency/q21$" "index.html" RewriteRule "^residency/summer-sessions$" "index.html" RewriteRule "^samawati/video$" "index.html" RewriteRule "^spectacular-spectator-mood-meter$" "index.html" @@ -73,6 +83,7 @@ RewriteRule "^@type/Event$" "index.html" RewriteRule "^@type/Report$" "index.html" RewriteRule "^@type/VideoObject$" "index.html" RewriteRule "^@type/MediaObject$" "index.html" +RewriteRule "^@type/EducationalOccupationalCredential$" "index.html" RewriteRule "^@type/ExhibitionEvent$" "index.html" RewriteRule "^@type/ImageObject$" "index.html" RewriteRule "^@type/Festival$" "index.html" @@ -83,5 +94,6 @@ RewriteRule "^@type/Person$" "index.html" RewriteRule "^@type/EventVenue$" "index.html" RewriteRule "^@type/Museum$" "index.html" RewriteRule "^@type/PerformingGroup$" "index.html" +RewriteRule "^@type/VisualArtsEvent$" "index.html" RewriteRule "^@type/CollegeOrUniversity$" "index.html" RewriteRule "^@type/WebSite$" "index.html" diff --git a/assets/css/portfolio.css b/assets/css/portfolio.css index f63ec40..d518b48 100644 --- a/assets/css/portfolio.css +++ b/assets/css/portfolio.css @@ -6,7 +6,7 @@ body { font-family: "DDINRegular", helvetica, sans-serif; font-weight: light; height: 100vh; - background: black; + background: #222; font-size: 12pt; } a, a:link, a:visited { @@ -162,7 +162,7 @@ text { width: 0; } #nodeDetails .nodeType { font-size: 80%; - text-transform: uppercase; + font-variant-caps: small-caps; color: #999; margin-left: 10px; } #nodeDetails .nodeType:hover { @@ -201,7 +201,8 @@ text { width: 170px; font-weight: bold; min-height: 25px; - clear: both; } + clear: both; + word-wrap: anywhere; } #nodeDetails dd { min-height: 30px; margin-top: 5px; } diff --git a/assets/js/portfolio.js b/assets/js/portfolio.js index 10ddba3..29e1be7 100644 --- a/assets/js/portfolio.js +++ b/assets/js/portfolio.js @@ -45,7 +45,7 @@ function getNodeYear(n) { return n['https://schema.org/datePublished'].substr(0, 4); } if (typeof n['https://schema.org/startDate'] !== 'undefined') { - console.log(n['https://schema.org/startDate']); + // console.log(n['https://schema.org/startDate']); return n['https://schema.org/startDate'].substr(0, 4); } if (typeof n['https://schema.org/endDate'] !== 'undefined') { @@ -125,10 +125,24 @@ var graph; var nodeMap = {}; var linkMap = {}; var breadcrumbs = {}; +var weights = {}; + // load the flattened jsonld file var requestPromise = fetch('/assets/js/rubenvandeven.jsonld').then(function (r) { return r.json(); -}).then(function (data) { +}); +var rankingPromise = fetch('/assets/js/ranking.json').then(function (r) { + return r.json(); +}); + +Promise.all([requestPromise, rankingPromise]).then(function (values) { + if (values[0].hasOwnProperty('@graph')) { + data = values[0]; + weights = values[1]; + } else { + data = values[1]; + weights = values[0]; + } graph = jsonLdToGraph(data['@graph']); // create a map of nodes by id. for (var i in graph.nodes) { @@ -199,8 +213,7 @@ var firstNodeId = "https://rubenvandeven.com/"; function getSizeForNode(node) { if (node.hasOwnProperty('https://schema.org/thumbnailUrl')) return nodeSize; - //if(weights[node['@id']]) - // return nodeSize * weights[node['@id']]; + if (weights[node['@id']]) return nodeSize * weights[node['@id']]; if (node['@id'] == firstNodeId) return nodeSize * 1.2; // everynode has at least one link. these should equal 1 return nodeSize * (.7 + Math.min(20, linkMap[node['@id']].length) / 40); @@ -534,7 +547,7 @@ function startGraph(graph) { deselectNode(); if (updateHistory) { // TODO: working - console.log(types[0], getDisplayAttr(types[0]), types.map(getDisplayAttr)); + // console.log(types[0], getDisplayAttr(types[0]),types.map(getDisplayAttr)); history.pushState({ types: types }, "", "/@type/" + types.map(getDisplayAttr).join("+")); } else { history.replaceState({ types: types }, "", "/@type/" + types.map(getDisplayAttr).join("+")); @@ -729,11 +742,17 @@ function startGraph(graph) { } } - // relationships / links in