perspectives:add to filter ctx menu

This commit is contained in:
Jan Prochazka
2022-08-04 08:26:35 +02:00
parent 9051ba2ee1
commit 97dc92e413
6 changed files with 53 additions and 27 deletions

View File

@@ -17,7 +17,19 @@
function createMenu() {
const customJoin = node.customJoinConfig;
const filterInfo = node.filterInfo;
return [
filterInfo && {
text: 'Add to filter',
onClick: () =>
setConfig(cfg => ({
...cfg,
filterInfos: {
...cfg.filterInfos,
[node.uniqueName]: filterInfo,
},
})),
},
customJoin && {
text: 'Remove custom join',
onClick: () =>