Skip to content

Commit 4faef30

Browse files
committed
Different fix for updating properties and fix wasm version fix #26
1 parent 0c2d6fa commit 4faef30

File tree

4 files changed

+6
-15
lines changed

4 files changed

+6
-15
lines changed

query-by-graph/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ crate-type = ["cdylib", "rlib"]
1414
default = ["console_error_panic_hook"]
1515

1616
[dependencies]
17-
wasm-bindgen = "=0.2.84"
17+
wasm-bindgen = "=0.2.93"
1818

1919
# The `console_error_panic_hook` crate provides better debugging of panics by
2020
# logging them with `console.error`. This is great for development, but requires

query-by-graph/src/lib.rs

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -109,11 +109,6 @@ fn graph_to_query(connections: Vec<Connection>) -> String {
109109
})
110110
.collect();
111111

112-
113-
114-
115-
116-
117112
format!(
118113
"{}\nSELECT {} WHERE {{\n{}}}",
119114
prefix_list, projection_list, where_clause

query-by-graph/src/lib/rete/editor.ts

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -123,14 +123,10 @@ export async function createEditor(container: HTMLElement) {
123123
// in order to force the editor to notice the change,
124124
// I need to create a copy of the connection,
125125
// change the entity and add it back.
126-
const thisConnection = deepCopy(editor.getConnection(id));
127-
128-
if (thisConnection) {
129-
thisConnection.property = value
130-
editor.removeConnection(id).then(() => {
131-
editor.addConnection(thisConnection);
132-
});
133-
}
126+
props.data.property = value;
127+
editor.getConnections().forEach((c) => {
128+
area.update("connection", c.id)
129+
})
134130
}
135131
});
136132
}

query-by-graph/src/lib/wikidata/WikibaseDataService.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -286,7 +286,7 @@ class WikibaseDataService {
286286
} else {
287287
labels[id] = id;
288288
}
289-
console.log('converting property id to label:', id, labels[id]);
289+
// console.log('converting property id to label:', id, labels[id]);
290290
}
291291
} else {
292292
console.error('No entities found in response:', response.data);

0 commit comments

Comments
 (0)