Skip to content

Commit

Permalink
better colors, more reactive suggestion
Browse files Browse the repository at this point in the history
  • Loading branch information
Leo-Nicolle committed Jan 15, 2024
1 parent addee82 commit f2a4a2c
Show file tree
Hide file tree
Showing 3 changed files with 27 additions and 26 deletions.
16 changes: 0 additions & 16 deletions client/src/components/Editor.vue
Original file line number Diff line number Diff line change
Expand Up @@ -345,22 +345,6 @@ const isLoadingSuggestions = computed(() => {
gap: 5px;
}
.unknown {
fill: rgba(252, 226, 42, 0.8);
}
.incomplete {
fill: rgba(214, 19, 85, 0.8);
}
.nodef {
fill: rgba(249, 74, 41, 0.8);
}
.noarrow {
fill: rgba(237, 43, 42, 0.8);
}
text.highlighted {
fill: #000;
}
Expand Down
7 changes: 6 additions & 1 deletion client/src/components/sidebars/Suggestion.vue
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
]" :data="results" :pagination="{
pageSize: 8,
simple: true,
}" @mousemove="onMouseEvt($event, false)" @click="onMouseEvt($event, true)" />
}" @mousemove="onMouseEvt($event, false)" @click="onMouseEvt($event, true)" @mouseout="onMouseOut" />
<n-button class="loading" v-else :loading="true"></n-button>
</div>
</template>
Expand Down Expand Up @@ -105,6 +105,11 @@ function onMouseEvt(evt: MouseEvent, click = false) {
hovered = text;
return click ? emit("click", text) : emit("hover", text);
}
function onMouseOut() {
hovered = "";
return emit("hover", '');
}
</script>

<style>
Expand Down
30 changes: 21 additions & 9 deletions client/src/components/svg-renderer/GridHighlight.vue
Original file line number Diff line number Diff line change
Expand Up @@ -222,7 +222,7 @@ function add() {
}
</script>

<style scoped>
<style>
.gridhighlightcontainer {
pointer-events: none;
display: grid;
Expand All @@ -232,7 +232,7 @@ function add() {
grid-area: 1 / 1 / 1 / 1;
}
.gridhighlight {
.gridhighlightcontainer>.gridhighlight {
top: 0;
left: 0;
padding: 0;
Expand All @@ -247,13 +247,13 @@ function add() {
pointer-events: none;
}
.highlight {
.gridhighlightcontainer>.gridhighlight>.highlight {
width: v-bind(width);
height: v-bind(height);
box-shadow: 0px 5px 10px 0px rgba(0, 0, 0, 0.5);
}
.gridhighlight>.tooltip {
.gridhighlightcontainer>.gridhighlight>.tooltip {
pointer-events: visible;
padding: 4px;
background-color: white;
Expand All @@ -267,35 +267,47 @@ function add() {
gap: 4px;
}
.heatmap {
.gridhighlightcontainer>.heatmap {
position: relative;
top: 0;
left: 0;
transform: v-bind(heatmapTransform);
pointer-events: none;
}
.lines {
.gridhighlightcontainer>.lines {
position: relative;
}
.lines>span {
.gridhighlightcontainer>.lines>span {
width: 1500px;
height: 1px;
background-color: red;
position: absolute;
}
.v-lines {
.gridhighlightcontainer>.v-lines {
position: relative;
}
.v-lines>span {
.gridhighlightcontainer>.v-lines>span {
left: 204px;
width: 102px;
height: 29px;
background-color: red;
position: absolute;
opacity: 0.5;
}
.incomplete {
fill: rgba(255, 107, 107, 0.8);
}
.nodef {
fill: rgba(17, 138, 178, 0.8);
}
.noarrow {
fill: rgba(255, 209, 102, 0.8);
}
</style>

0 comments on commit f2a4a2c

Please sign in to comment.