Skip to content

Commit

Permalink
Merge dev into main for v1.1.0 release
Browse files Browse the repository at this point in the history
  • Loading branch information
RinkeHoekstra committed Mar 29, 2024
2 parents 4867bd6 + b534d3e commit 95c543b
Show file tree
Hide file tree
Showing 5 changed files with 26 additions and 80 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
node_modules
*/node_modules
out
dist
*.vsix
.DS_Store
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
},
"repository": "https://github.com/elsevierlabs-os/linked-data",
"description": "This extension provides shortcuts for standard Linked Data operations, format conversions, validation, querying and a graph visualization.",
"version": "1.0.9",
"version": "1.1.0",
"icon": "media/img/lde-icon.png",
"engines": {
"vscode": "^1.75.0"
Expand Down
12 changes: 6 additions & 6 deletions src/extension.ts
Original file line number Diff line number Diff line change
Expand Up @@ -795,7 +795,7 @@ export function activate(context: vscode.ExtensionContext) {
let document = editor.document ;

// Try to obtain YAML configuration from comments at the top of the query
const re = /^(#.+\n)+/;
const re = /^(#.+\r?\n)+/;
const m = document.getText().match(re);
var shaclFileName;

Expand Down Expand Up @@ -915,7 +915,7 @@ export function activate(context: vscode.ExtensionContext) {
const query = document.getText();

// Try to obtain YAML configuration from comments at the top of the query
const re = /^(#.+\n)+/;
const re = /^(#.+\r?\n)+/;
const m = query.match(re);
var dataFileName;

Expand Down Expand Up @@ -970,13 +970,13 @@ export function activate(context: vscode.ExtensionContext) {
var data = [];

if (result.length > 0) {
// Iterate over the keys of the first result to obtain the array of variables.
for(let v of result[0].keys()){
variables.push(v);
}
for(let r of result){
let stringresult = [];
for(let v of r.keys()){ // variables are key in the map

if (!variables.includes(v)) {
variables.push(v);
}
if (r.get(v).value != undefined) {
stringresult.push(r.get(v).value);
} else {
Expand Down
87 changes: 15 additions & 72 deletions src/inspector.css
Original file line number Diff line number Diff line change
@@ -1,64 +1,3 @@

/* .links path {
stroke: #444;
stroke-opacity: 0.6;
}
marker {
stroke: #444;
fill: #444;
stroke-width: 0.1;
}
.edgelabel textPath {
fill: #444;
}
.nodes circle {
stroke: #fff;
stroke-width: 1.5px;
}
text {
font-family: "Elsevier Display", sans-serif;
font-size: 10px;
}
.d3-tip {
line-height: 1;
padding: 6px;
background: rgba(0, 0, 0, 0.8);
color: #fff;
border-radius: 4px;
font-family: "Elsevier Display", sans-serif;
}
table {
max-width: 500px;
vertical-align: top;
}
th, td {
vertical-align: top;
}
td {color: lightgray;}
svg {
width: 100%;
padding-bottom: 92%;
height: 1px;
overflow: visible
} */



/* svg {
border: 1px solid #ccc;
} */


svg {
width: 100%;
padding-bottom: 92%;
Expand All @@ -69,6 +8,21 @@ svg {
body {
font: 10px sans-serif;
}

body.vscode-light {
color: black;
fill: black;
}

body.vscode-dark {
color: white;
fill: white;
}

body.vscode-high-contrast {
color: red;
}

circle.node {
fill: lightsteelblue;
stroke: #555;
Expand All @@ -89,14 +43,3 @@ div.tooltip {
position: absolute;
display: block;
}

/* table {
max-width: 500px;
vertical-align: top;
}
th, td {
vertical-align: top;
}
td {color: lightgray;} */
4 changes: 3 additions & 1 deletion src/inspector.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import * as d3 from "d3";
import { default as d3tip } from "d3-tip";
// import { on } from "events";
import { on } from "events";
import css from './inspector.css';

document.addEventListener('DOMContentLoaded', function() {
const dataContents = window.document.getElementById('data').innerText;
Expand Down Expand Up @@ -128,6 +129,7 @@ function ForceGraph({nodes, links}, // a dictionary with nodes and links arrays.
.style("opacity", 0)
.attr("class","tooltip")
.style("background-color", "white")
.style("color","rgb(36, 41, 46)")
.style("border", "solid")
.style("border-width", "2px")
.style("border-radius", "5px")
Expand Down

0 comments on commit 95c543b

Please sign in to comment.