AIMPED
November 30, 2022, 3:21pm
5
Hi @stamljf , I don’t know about JS, but in python the shapes are stored in a list. Here is an example app where I delete some shapes based on the name:
Hi @iacisme this is a quick & dirty example in dash. I know you do not want to use dash, I will try to answer your question by just using plotly, but I actually never used shapes in pure plotly.
Anyways, the section where I delete the shapes is in the callback. After the name has been introduced in the dcc.Input() and the delete button has been clicked.
from dash import Dash, dcc, html, Input, Output, State
import dash_bootstrap_components as dbc
from dash.exceptions import PreventUpdate
impor…