WIP history and sizing

This commit is contained in:
Ruben van de Ven 2019-11-22 20:11:07 +01:00
parent a0011ec660
commit b8985cbbda
3 changed files with 120 additions and 56 deletions

View File

@ -4,6 +4,7 @@
<title></title>
<link href="/rubenvandeven.jsonld" rel="alternate" type="application/ld+json" />
<link rel="stylesheet" href="/assets/css/portfolio.css">
<link rel="icon" href="/icon.svg" />
<meta property="og:title" content="Ruben van de Ven" />
<meta property="og:type" content="website" />
<meta property="og:image" content="/assets/og_image2.png" />

View File

@ -1,14 +1,16 @@
{
"@context": {
"@vocab": "https://schema.org/",
"s": "http://www.w3.org/2000/01/rdf-schema#"
"s": "http://www.w3.org/2000/01/rdf-schema#",
"r": "https://rubenvandeven.com"
},
"@type": "WebSite",
"@id": "r:#site",
"url": "https://rubenvandeven.com",
"s:seeAlso": [ "https://rubenvandeven.com/rubenvandeven.jsonld", "https://rubenvandeven.com/foaf.rdf#me"],
"author":
{
"@id": "https://rubenvandeven.com/#me",
"@id": "r:/",
"@type": "Person",
"name": "Ruben van de Ven",
"jobTitle": "digital artist / researcher of software culture",
@ -17,18 +19,19 @@
"@reverse": {
"member": [
{
"@id": "https://rubenvandeven.com/member/plottingdata",
"@id": "r:/plottingdata",
"@type": "PerformingGroup",
"name": "Plotting Data: dramatisation as tactic",
"url": "http://plottingd.at/a",
"foundingDate": "2018",
"description": "A research into <em>Data Dramatisation</em> as a tactic to make data visualisations more transparent in their underlying procedures of data collection. We advocate a form of data literacy that is not so much focussed on programming skill, but rather one that brings an understanding of data infrastructures: allowing for restistance against data driven governance.",
"member": [
{"@id": "https://rubenvandeven.com/person/cristina-cochior"}
{"@id": "r:/person/cristina-cochior"}
],
"@reverse": {
"about": [
{
"@id": "r:/2018/digital-cultures",
"@type": "Event",
"name": "Digital Cultures: Knowledge / Culture / Technology",
"url": "https://digitalculturesconference.org/",
@ -40,6 +43,7 @@
],
"organizer": [
{
"@id": "r:/2018/data-flaneur",
"@type": "Event",
"name": "Data Flâneur",
"alternateName": "Data Flâneur - seeing and being seen in the data driven city",
@ -48,6 +52,7 @@
"url":"https://creativecodingutrecht.nl/2018/10/20/the-data-flaneur-seen-and-being-seen-in-the-data-driven-city-tour/",
"description": "Inspired by Alison Powells data walk, the <em>Flaneur</em> twists her concept by not only making participants aware of data collection within the city, but also by making them experiment with data collection for their own purposes. By zooming in on the procedures of selection, classification and digitisation, participants experience the intricacies of data collection.",
"superEvent": {
"@id": "r:/exhibition/hello-world",
"@type": "ExhibitionEvent",
"name": "Hello World!",
"startDate": "2018-11-02",
@ -62,7 +67,7 @@
],
"attendee": [
{
"@id": "http://summersessions.net/17-projects/projects-2016/55-emotion-hero#id",
"@id": "r:/residency/summer-sessions",
"@type": "VisualArtsEvent",
"name": "Residency: Summer Sessions 2016",
"url": "http://summersessions.net/17-projects/projects-2016/55-emotion-hero",
@ -70,32 +75,34 @@
"startDate": "2016-09",
"endDate": "2016-10",
"about": {
"@id": "https://rubenvandeven.com/emotionhero"
"@id": "r:/emotionhero"
}
},
{
"@id": "r:/residency/q21",
"@type": "VisualArtsEvent",
"name": "Residency: Q21",
"startDate": "2017-01",
"endDate": "2017-02",
"@reverse": {
"subEvent": {
"@id": "https://rubenvandeven.com/exhibition/mood_swings"
"@id": "r:/exhibition/mood_swings"
}
},
"location": {
"@id": "https://rubenvandeven.com/place/q21"
"@id": "r:/place/q21"
}
},
{
"@id": "http://cqrrelations.constantvzw.org/",
"@id": "r:/event/cqrrelations",
"@type": "Event",
"name": "Cqrrelations Worksession",
"url": "http://cqrrelations.constantvzw.org/",
"startDate": "2015-01-18",
"endDate": "2015-01-23",
"organizer": {
"@id": "http://constantvzw.org",
"@id": "r:/organisation/constant",
"url": "http://constantvzw.org",
"@type": "Organization",
"name": "Constant"
}
@ -103,40 +110,54 @@
],
"author": [
{
"@id": "r:/ghost-worker",
"@type": "MediaObject",
"name": "Ghost Worker",
"dateCreated": "2019",
"description": "Nowadays, we are not only increasingly delegating and automating tasks and processes, there also new forms of work that are being created for people. With the emergence of services such as Amazon's Mechanical Turk, specific parts of automatic processes are being outsourced to human workers. These Human Intelligence Tasks are tasks that a machine cannot execute, for example retyping a scanned receipt or entering a Captcha code. In this way machines selectively delegate tasks to humans, creating a human working class that remains largely invisible.Merijn van Moll and Ruben van de Ven want to make this feedback loop between man and machine visible. This creates a new ritual in which the spirit of the worker is invoked again and again.\n\nThis project was developed in light of <em>Future scenarios for AI and the job market</em> by Setup and the NSvP (Dutch Foundation for Psycho technology)",
"image": [
{
"@id": "r:/ghost-worker/image/1",
"@type": "ImageObject",
"contentUrl": "assets\/image\/ghost_worker01.jpg",
"thumbnailUrl": "assets\/thumb\/ghost_worker01.jpg"
},
{
"@id": "r:/ghost-worker/image/2",
"@type": "ImageObject",
"contentUrl": "assets\/image\/ghost_worker02.jpg",
"thumbnailUrl": "assets\/thumb\/ghost_worker02.jpg"
},
{
"@id": "r:/ghost-worker/image/3",
"@type": "ImageObject",
"contentUrl": "assets\/image\/ghost_worker03.jpg",
"thumbnailUrl": "assets\/thumb\/ghost_worker03.jpg"
},
{
"@id": "r:/ghost-worker/image/4",
"@type": "ImageObject",
"contentUrl": "assets\/image\/ghost_worker04.jpg",
"thumbnailUrl": "assets\/thumb\/ghost_worker04.jpg"
}
],
"video": {
"@id": "r:/ghost-worker/video/1",
"@type": "VideoObject",
"thumbnailUrl": "http://works.rubenvandeven.com/2019-ghost_worker/ghostworkers-without-credits.mp4",
"contentUrl": "http://works.rubenvandeven.com/2019-ghost_worker/ghostworkers-without-credits.mp4" ,
"encodingFormat": "video/mp4",
"videoFrameSize": "1280x1024"
},
"author": {
"@id": "https://rubenvandeven.com/person/merijn-van-moll",
"@id": "r:/person/merijn-van-moll",
"@type": "Person",
"name": "Merijn van Moll",
"url": "https://merijnvanmoll.nl/"
}
},
{
"@id": "r:/diede",
"@type": "MediaObject",
"name": "Writing lesson",
"dateCreated": "2019",
@ -144,11 +165,13 @@
"s:seeAlso": [ "https://gitlab.com/rubenvandeven/diede"],
"image": [
{
"@id": "r:/diede/image/2",
"@type": "ImageObject",
"contentUrl": "assets\/image\/diede-2.jpg",
"thumbnailUrl": "assets\/thumb\/diede-2.jpg"
},
{
"@id": "r:/diede/image/1",
"@type": "ImageObject",
"contentUrl": "assets\/image\/diede-1.jpg",
"thumbnailUrl": "assets\/thumb\/diede-1.jpg"
@ -156,6 +179,7 @@
]
},
{
"@id": "r:/sustaining-gazes",
"@type": "MediaObject",
"name": "Sustaining Gazes",
"dateCreated": "2018",
@ -163,10 +187,12 @@
"@reverse": {
"workFeatured": [
{
"@id": "r:/exhibition/route-du-nord",
"@type": "ExhibitionEvent",
"name": "Route du Nord",
"url": "http://routedunord.nl/portfolio-item/ruben-van-de-ven-2/",
"location": {
"@id": "r:/venue/zoho",
"@type": "EventVenue",
"name": "ZOHO",
"address": "Rotterdam"
@ -176,10 +202,12 @@
"workFeatured": []
},
{
"@id": "r:/exhibition/the-new-current",
"@type": "ExhibitionEvent",
"name": "The New Current",
"url": "https://www.thenewcurrent.org/artists-artweek",
"location": {
"@id": "r:/venue/cruise-terminal",
"@type": "EventVenue",
"name": "Cruise Terminal",
"address": "Rotterdam"
@ -192,11 +220,13 @@
},
"image": [
{
"@id": "r:/sustaining-gazes/image/1",
"@type": "ImageObject",
"contentUrl": "assets\/image\/sustaining-gazes-2.jpg",
"thumbnailUrl": "assets\/thumb\/sustaining-gazes-2.jpg"
},
{
"@id": "r:/sustaining-gazes/image/2",
"@type": "ImageObject",
"contentUrl": "assets\/image\/sustaining-gazes-1.jpg",
"thumbnailUrl": "assets\/thumb\/sustaining-gazes-1.jpg"
@ -204,12 +234,14 @@
]
},
{
"@id": "r:/mvps",
"@type": "CreativeWorkSeries",
"name": "MVPs",
"about": "November 2017 In4Art approached me to be part of their KickstART project. They commissioned three works to be part of their auction. The goal was to explicitly develop works that fitted the commercial art scene.\n\nRather than creating 'sellable' works myself, I took the start-up culture that forms the foundation of In4Art, as my object of my series. I augmented the works of three other participants with business models taken from the online/digital realm. This resulted in three <em>Minimum Viable Products</em>. Recontextualising these business models towards an arts context, results in new perspectives on both the arts as well as start-up culture.",
"dateCreated":"2018",
"hasPart": [
{
"@id": "r:/mvp1",
"@type": "MediaObject",
"name": "MVP#1 Gathering viewing statistics for Donald Schenkel",
"dateCreated": "2018",
@ -218,7 +250,7 @@
"height": "55cm + 8cm",
"artworkSurface": "Oilpaint on wood + WiFi-connected RaspberryPi in ABS enclosure",
"contributor": {
"@id": "http://www.donaldschenkel.nl/#person",
"@id": "r:/person/donald-schenkel",
"@type": "Person",
"name": "Donald Schenkel",
"url": "http://www.donaldschenkel.nl/"
@ -226,11 +258,11 @@
"@reverse": {
"workFeatured": [
{
"@id": "https://rubenvandeven.com/#kick2018exhibit",
"@id": "r:/exhibition/kickstart",
"@type": "ExhibitionEvent",
"name": "KickstART",
"location": {
"@id": "https://rubenvandeven.com/place/in4art",
"@id": "r:/place/in4art",
"@type": "EventVenue",
"name": "In4Art Project Space",
"address": "Amsterdam"
@ -239,11 +271,11 @@
"endDate": "2018-03-28"
},
{
"@id": "https://rubenvandeven.com/#in4artSalon",
"@id": "r:/in4art-salon",
"@type": "ExhibitionEvent",
"name": "Salon VI - Innovatism",
"location": {
"@id": "https://rubenvandeven.com/place/in4art"
"@id": "r:/place/in4art"
},
"startDate": "2018-05-18",
"endDate": "2018-05-27"
@ -252,16 +284,19 @@
},
"image": [
{
"@id": "r:/mvp1/image/1",
"@type": "ImageObject",
"contentUrl": "assets\/image\/mvp1-1.jpg",
"thumbnailUrl": "assets\/thumb\/mvp1-1.jpg"
},
{
"@id": "r:/mvp1/image/2",
"@type": "ImageObject",
"contentUrl": "assets\/image\/mvp1-2.jpg",
"thumbnailUrl": "assets\/thumb\/mvp1-2.jpg"
},
{
"@id": "r:/mvp1/image/3",
"@type": "ImageObject",
"contentUrl": "assets\/image\/mvp1-4.jpg",
"thumbnailUrl": "assets\/thumb\/mvp1-4.jpg"
@ -269,6 +304,7 @@
]
},
{
"@id": "r:/mvp2",
"@type": "MediaObject",
"name": "MVP#2 Joseph Huot's Limited Edition",
"dateCreated": "2018",
@ -277,7 +313,7 @@
"height":"50cm",
"artworkSurface": "Pencil drawing in metal LCD enclosure",
"contributor": {
"@id": "http://www.joseph-huot.com/#person",
"@id": "r:/person/joseph-huot",
"@type": "Person",
"name": "Joseph Huot",
"url": "http://www.joseph-huot.com/"
@ -285,21 +321,24 @@
"@reverse": {
"workFeatured":
{
"@id": "https://rubenvandeven.com/#kick2018exhibit"
"@id": "r:/exhibition/kickstart"
}
},
"image": [
{
"@id": "r:/mvp2/image/1",
"@type": "ImageObject",
"contentUrl": "assets\/image\/mvp2-01.jpg",
"thumbnailUrl": "assets\/thumb\/mvp2-01.jpg"
},
{
"@id": "r:/mvp2/image/2",
"@type": "ImageObject",
"contentUrl": "assets\/image\/mvp2-02.jpg",
"thumbnailUrl": "assets\/thumb\/mvp2-02.jpg"
},
{
"@id": "r:/mvp2/image/3",
"@type": "ImageObject",
"contentUrl": "assets\/image\/mvp2-5.jpg",
"thumbnailUrl": "assets\/thumb\/mvp2-5.jpg"
@ -307,6 +346,7 @@
]
},
{
"@id": "r:/mvp3",
"@type": "MediaObject",
"name": "MVP#3 Customiseyour.art - Mikel Folgerts 1/3",
"dateCreated": "2018",
@ -315,6 +355,7 @@
"height":"40cm",
"artworkSurface": "Personalised print on perspex",
"contributor": {
"@id": "r:/person/mikel-folgerts",
"@type": "Person",
"name": "Mikel Folgerts",
"url": "https://www.instagram.com/mikelfolgerts/"
@ -322,11 +363,12 @@
"@reverse": {
"workFeatured":
{
"@id": "https://rubenvandeven.com/#kick2018exhibit"
"@id": "r:/exhibition/kickstart"
}
},
"image": [
{
"@id": "r:/mvp3/image/1",
"@type": "ImageObject",
"contentUrl": "assets\/image\/mvp3-1.jpg",
"thumbnailUrl": "assets\/thumb\/mvp3-1.jpg"
@ -336,12 +378,13 @@
]
},
{
"@id": "r:/spectacular-spectator-mood-meter",
"@type": "MediaObject",
"name": "Spectacular Spectator Mood Meter",
"dateCreated": "2017",
"description": "Commisioned by V2_ for Evening of the Black Box Concern. Researchers of digital culture often regard artificial intelligence as <em>black boxes</em>. However, developers of these systems often regard the humans that are analysed as black boxes.\n\nWhat happens when we use black boxes (AI) to analyse black boxes (humans) and present these back to black boxes (humans)?\n\nThis prototype used emotion recognition software by Affectiva to analyse the audience of the talks. It then highlighted the moments in the talks for which outliers in the data were found. Can we use this data to analyse either of the black boxes?",
"producer": {
"@id": "https://rubenvandeven.com/#v2_"
"@id": "r:/organisation/v2_"
},
"@reverse": {
"workFeatured": [
@ -350,7 +393,7 @@
"name": "Evening of the Black Box Concerns",
"url": "http://v2.nl/events/evening-of-the-black-box-concerns",
"location": {
"@id": "https://rubenvandeven.com/#v2_"
"@id": "r:/organisation/v2_"
},
"startDate": "2017-12-7",
"workFeatured": []
@ -381,7 +424,7 @@
]
},
{
"@id": "https://rubenvandeven.com/emotionhero",
"@id": "r:/emotionhero",
"@type": "MediaObject",
"dateCreated": "2016",
"name": "Emotion Hero",
@ -417,11 +460,11 @@
]
},
{
"@id": "https://rubenvandeven.com/exhibition/mood_swings",
"@id": "r:/exhibition/mood_swings",
"@type": "ExhibitionEvent",
"name": "Mood Swings",
"location": {
"@id": "https://rubenvandeven.com/place/q21",
"@id": "r:/place/q21",
"@type": "Museum",
"name": "frei_raum / Q21",
"address": "MuseumsQuartier /Vienna"
@ -464,7 +507,7 @@
},
"startDate": "2017-09",
"endDate": "2017-09",
"organiser": { "@id":"vhttps://rubenvandeven.com/#2_" },
"organiser": { "@id":"r:/organisation/v2_" },
"funded": "Creative Industries Fund",
"workFeatured": []
},
@ -483,7 +526,7 @@
"workFeatured": []
},
{
"@id": "https://rubenvandeven.com/#codesandmodes",
"@id": "r:/exhibition/codesandmodes",
"@type": "ExhibitionEvent",
"url": "https://www.hunterintegratedmedia.org/reframe/speaker-lineup/ruben-van-de-ven/",
"name": "Codes & Modes II",
@ -501,7 +544,7 @@
}
},
{
"@id": "https://rubenvandeven.com/#stateofemotion",
"@id": "r:/exhibition/stateofemotion",
"@type": "ExhibitionEvent",
"name": "STATE of Emotion",
"@reverse": {
@ -575,7 +618,7 @@
"name": "Test_Lab the Graduation Edition",
"url": "http://v2.nl/events/test_lab-the-graduation-edition-2015-1/",
"location": {
"@id": "https://rubenvandeven.com/#v2_",
"@id": "r:/organisation/v2_",
"@type": "Place",
"name": "V2_",
"address": "Rotterdam"
@ -619,7 +662,7 @@
"duration": "11:32 (∞ loop)",
"description": "Whether the video frames are ordered by time or by emotion will not make a difference to a computer. For it, both orderings are just as logical. However, for the human spectator the reordered display of frames becomes a disruptive process. The human is positioned as a required agent for meaning making in an algorithmic procedure.\n\nIn collaboration with Cristina Cochior I went manually through the Eye's public collection, and catalogued faces by surrendering them to an emotion detection algorithm. Cutting from one face to another,its uncritical selection produced a new portrait of emotional gradients moving in-between anger and happiness.",
"author": {
"@id": "https://rubenvandeven.com/person/cristina-cochior",
"@id": "r:/person/cristina-cochior",
"@type": "Person",
"name": "Cristina Cochior",
"url": "http://randomizer.info"
@ -692,7 +735,7 @@
"datePublished": "2017-01-27"
},
{
"@id": "http://networkcultures.org/longform/2017/01/25/choose-how-you-feel-you-have-seven-options/#article",
"@id": "r:/article/choose-how-you-feel-you-have-seven-options",
"@type": "Report",
"name": "Longform - Choose How You Feel; You Have Seven Options",
"description": "What does it mean to feel 82% surprised or 93% joy? As part of their Longform series, the Institute of Network Cultures published my research into software that derives emotional scores from facial expressions.",
@ -891,10 +934,10 @@
"@reverse": {
"workFeatured": [
{
"@id": "https://rubenvandeven.com/#codesandmodes"
"@id": "r:/exhibition/codesandmodes"
},
{
"@id": "https://rubenvandeven.com/#stateofemotion"
"@id": "r:/exhibition/stateofemotion"
},
{
"@type": "ExhibitionEvent",
@ -904,7 +947,7 @@
"endDate": "2015-06-27",
"description": "What is an encyclopedia? What are media? What is an object? Students of the Piet Zwart Institute Media Design Masters programme invite you to look at these issues. Twelve installations and one choreography present a taxonomy of disappearing, human and non-human, introvert and collected media objects.\n\nThis exhibition was developed in a 'Thematic Seminar' run in the summer trimester 2015 taught by Florian Cramer.\n\nArtists: Lucas Battich [IT], Manetta Berends [NL], Julie Boschat Thorez [FR], Cihad Caner [TR], Joana Chicau [PT], Cristina Cochior [RO], Solange Frankort [NL], Arantxa Gonlag [NL], Anne Lamb [US], Benjamin Li [NL], Yuzhen Tang [CN], Ruben van de Ven [NL] & Thomas Walskaar [NO]",
"location": {
"@id": "https://rubenvandeven.com/#v2_"
"@id": "r:/organisation/v2_"
}
}
]
@ -1020,7 +1063,7 @@
}
],
"video": {
"@id": "https://rubenvandeven.com/assets/video/samawati.mp4#videoobject",
"@id": "r:/assets/video/samawati.mp4#videoobject",
"@type": "VideoObject",
"thumbnailUrl": "assets/thumb/samawati.mp4.jpg",
"contentUrl": "assets/video/samawati.mp4" ,
@ -1041,7 +1084,7 @@
}
],
"video": {
"@id": "https://rubenvandeven.com/assets/video/guerilla_project.mp4#videoobject",
"@id": "r:/assets/video/guerilla_project.mp4#videoobject",
"@type": "VideoObject",
"contentUrl": "assets/video/guerilla_project.mp4",
"thumbnailUrl": "assets/thumb/guerilla_project.mp4.jpg",
@ -1132,7 +1175,7 @@
"name": "The Specta­cular Times",
"dateCreated": "2013-12-04",
"author": {
"@id": "http://www.wardgoes.nl/#person",
"@id": "r:/person/ward-goes",
"@type": "Person",
"name": "Ward Goes",
"url": "http://www.wardgoes.nl"

View File

@ -154,6 +154,23 @@ function createLinkMap(graph) {
return linkMap;
}
// config
var nodeSize = 40;
var selectedNodeSize = 140;
var firstNodeId = "https://rubenvandeven.com/";
var startNodeId = location.search.startsWith("?id=") ? location.search.substr(4) : 'https://rubenvandeven.com'+location.pathname;
function getSizeForNode(node) {
if(node.hasOwnProperty('https://schema.org/thumbnailUrl'))
return nodeSize;
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)
return nodeSize;
}
// TODO: make sure, 'shortest' path is favoured.
function createBreadcrumbs(linkMap, srcId) {
let crumbs = {};
@ -189,11 +206,6 @@ var nodePositions = {};
function startGraph(graph){
// config
var nodeSize = 40;
var selectedNodeSize = 140;
var firstNodeId = "https://rubenvandeven.com/#me";
// set some vars
var currentNodeIdx = 0;
var currentNodePositionRadius = 0;
@ -280,7 +292,9 @@ var container = svg.append("g")
var simulation = d3.forceSimulation()
.force("link", d3.forceLink().id(function(d) { return d["@id"]; }).strength(.005))
.force("charge", d3.forceManyBody()) // doesn't seem necessary?
.force("collision", d3.forceCollide(nodeSize * 1.1)) // avoid overlapping nodes
.force("collision", d3.forceCollide(function(d){
return getSizeForNode(d) * 1.1; // avoid overlapping nodes
}))
// .force("center", d3.forceCenter(width / 2, height / 2)) // position around center
// .force("x", d3.forceX())
@ -674,7 +688,13 @@ var selectNode = function(idx, updateHistory){
if(updateHistory) {
history.pushState({node: idx}, getNodeLabel(nodeDatum), "/"+nodeDatum['@id']);
let id = null;
if(nodeDatum['@id'].startsWith(/*location.origin*/'https://rubenvandeven.com/')){
id = nodeDatum['@id'].substr(26);
} else {
id = '?id=' + nodeDatum['@id'];
}
history.pushState({node: idx}, getNodeLabel(nodeDatum), "/"+id);
}
// set global var
@ -820,9 +840,9 @@ simulation.force('centerActive', function force(alpha) {
//path to curve the tile
var nodePath = node.append("path")
.attr("id", function(d,idx){return "nodePath"+idx;})
.attr("d", function(){
var r = nodeSize * 0.9;
var startX = nodeSize;
.attr("d", function(d){
var r = getSizeForNode(d) * 0.9;
var startX = getSizeForNode(d);
// M cx cy
// m -r, 0
// a r,r 0 1,0 (r * 2),0
@ -891,11 +911,11 @@ svg.call(d3.zoom()
// svg.call(d3.zoom.transform, d3.zoomIdentity);
node.append('circle')
.attr("r", nodeSize)
.attr("r", (d) => getSizeForNode(d))
.attr("class", "nodeBg")
;
node.append('circle')
.attr("r", nodeSize * 1.08) // nodeSize + margin
.attr("r", (d) => getSizeForNode(d) * 1.08) // nodeSize + margin
.attr("class", "highlightCircle")
;
@ -988,8 +1008,8 @@ nodeTitle
}
// scale according to text length:
if(textLength > nodeSize * 2) {
self.attr('transform', `scale(${(nodeSize * 2) / textLength / 1.05})`);
if(textLength > getSizeForNode(node) * 2) {
self.attr('transform', `scale(${(getSizeForNode(node) * 2) / textLength / 1.05})`);
}
})
;
@ -1000,9 +1020,9 @@ node.each(function(d) {
}
d3.select(this).append('svg:image')
.attr("xlink:href", d['https://schema.org/thumbnailUrl'])
.attr("width", nodeSize*2)
.attr("height", nodeSize*2)
.attr("transform","translate(-"+nodeSize+" -"+nodeSize+")")
.attr("width", (d) => getSizeForNode(d)*2)
.attr("height", (d) => getSizeForNode(d)* 2)
.attr("transform",(d) => "translate(-"+getSizeForNode(d)+" -"+getSizeForNode(d)+")")
.attr("clip-path","url(#clipNodeImage)")
.attr("preserveAspectRatio","xMidYMid slice")
;
@ -1077,8 +1097,8 @@ function ticked() {
srcSize = (typeof nodePositions[d.source.index] != 'undefined') ? selectedNodeSize : nodeSize;
tgtSize = (typeof nodePositions[d.target.index] != 'undefined') ? selectedNodeSize : nodeSize;
*/
let srcSize = nodeSize+3.2;
let tgtSize = nodeSize+3.2;
let srcSize = getSizeForNode(d.source)+3.2;
let tgtSize = getSizeForNode(d.target)+3.2;
// Compute the line endpoint such that the arrow
// is touching the edge of the node rectangle perfectly.
@ -1145,7 +1165,7 @@ function moveViewboxPx(dx, dy){
// start by selecting the first node :-)
// selectNode(currentNodeIdx+1);
// positionNodesInCenter(currentNodeIdx);
var firstNode = graph['nodes'].find(n => n['@id'] === firstNodeId);
var firstNode = graph['nodes'].find(n => n['@id'] === startNodeId);
selectNode(graph['nodes'].indexOf(firstNode), false);
// closeDetails(); // hide details at first