From 1f5fa928f82eb8c9206b24765e0ea520097780b0 Mon Sep 17 00:00:00 2001 From: Tanguy-DES Date: Wed, 3 May 2023 17:38:23 +0200 Subject: [PATCH 1/3] fix(selectionchange_pp): update selected_point_index in pp --- src/multiplots.ts | 3 +-- src/subplots.ts | 1 + 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/multiplots.ts b/src/multiplots.ts index a71faf3a..90aa6d18 100644 --- a/src/multiplots.ts +++ b/src/multiplots.ts @@ -1626,6 +1626,7 @@ export class MultiplePlots { manage_selected_point_index_changes(old_selected_index:number[]) { if (!equals(old_selected_index, this.selected_point_index)) { var evt = new CustomEvent('selectionchange', { detail: { 'selected_point_indices': this.dep_selected_points_index } }); + console.log(this.selected_point_index) this.canvas.dispatchEvent(evt); } } @@ -1806,8 +1807,6 @@ export class MultiplePlots { var clickOnVertex:boolean = false; var old_selected_index; var double_click = false; - - // For canvas to read keyboard inputs. // this.canvas.setAttribute('tabindex', '0'); // this.canvas.focus(); diff --git a/src/subplots.ts b/src/subplots.ts index d5d476b1..f8d368b3 100644 --- a/src/subplots.ts +++ b/src/subplots.ts @@ -415,6 +415,7 @@ export class ParallelPlot extends PlotData { } } }) + this.selected_point_index = selectedIndices; return selectedIndices } } From b2773a8525547327b089ae2634d656c3cc04b9b7 Mon Sep 17 00:00:00 2001 From: Tanguy-DES Date: Wed, 3 May 2023 17:40:43 +0200 Subject: [PATCH 2/3] fix(selectionchange_pp): remove console.log --- src/multiplots.ts | 1 - 1 file changed, 1 deletion(-) diff --git a/src/multiplots.ts b/src/multiplots.ts index 90aa6d18..7835cc4d 100644 --- a/src/multiplots.ts +++ b/src/multiplots.ts @@ -1626,7 +1626,6 @@ export class MultiplePlots { manage_selected_point_index_changes(old_selected_index:number[]) { if (!equals(old_selected_index, this.selected_point_index)) { var evt = new CustomEvent('selectionchange', { detail: { 'selected_point_indices': this.dep_selected_points_index } }); - console.log(this.selected_point_index) this.canvas.dispatchEvent(evt); } } From 18ba6b327bccfcfef541c61a3e90a718b581fea4 Mon Sep 17 00:00:00 2001 From: Tanguy-DES Date: Wed, 3 May 2023 17:50:55 +0200 Subject: [PATCH 3/3] fix(selchange_pp) changelog --- CHANGELOG.md | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index b669c327..410f7cdb 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,12 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). + +## [0.12.2] +### Fix +- update selected_point_index when selecting from parallelplot + + ## [0.12.1] ### Fix - npmignore