aboutsummaryrefslogtreecommitdiff
path: root/src/client/views/PropertiesDocContextSelector.tsx
diff options
context:
space:
mode:
authorbobzel <zzzman@gmail.com>2024-02-26 14:45:02 -0500
committerbobzel <zzzman@gmail.com>2024-02-26 14:45:02 -0500
commitab658feb8d5a0a2c7eb2bd213bff227b7accb23a (patch)
tree5376678ab8d2b4cc63c7aad954816e40f0d32667 /src/client/views/PropertiesDocContextSelector.tsx
parentd99f64efe9e69f2159f1ad8f851b24533a996ba5 (diff)
fixed tooltips to not grab events - this made moving down a menu a problem since the tooltip blocked the next menu item and wouldn't give the hover event to the next menu item. fixed proto_embeddings to update when lassoing a collection in marqueeView which made showContexts in property view do the right thing.
Diffstat (limited to 'src/client/views/PropertiesDocContextSelector.tsx')
-rw-r--r--src/client/views/PropertiesDocContextSelector.tsx4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/client/views/PropertiesDocContextSelector.tsx b/src/client/views/PropertiesDocContextSelector.tsx
index 361451c4d..b8bbde9de 100644
--- a/src/client/views/PropertiesDocContextSelector.tsx
+++ b/src/client/views/PropertiesDocContextSelector.tsx
@@ -30,12 +30,12 @@ export class PropertiesDocContextSelector extends ObservableReactComponent<Prope
const targetContext = this._props.DocView.containerViewPath?.().lastElement()?.Document;
const embeddings = Doc.GetEmbeddings(target);
const containerProtos = embeddings.filter(embedding => embedding.embedContainer && embedding.embedContainer instanceof Doc).reduce((set, embedding) => set.add(Cast(embedding.embedContainer, Doc, null)), new Set<Doc>());
- const containerSets = Array.from(containerProtos.keys()).map(container => Doc.GetEmbeddings(container));
+ const containerSets = Array.from(containerProtos.keys()).map(container => (Doc.GetEmbeddings(container).length ? Doc.GetEmbeddings(container) : [container]));
const containers = containerSets.reduce((p, set) => {
set.map(s => p.add(s));
return p;
}, new Set<Doc>());
- const doclayoutSets = Array.from(containers.keys()).map(dp => Doc.GetEmbeddings(dp));
+ const doclayoutSets = Array.from(containers.keys()).map(dp => (Doc.GetEmbeddings(dp).length ? Doc.GetEmbeddings(dp) : [dp]));
const doclayouts = Array.from(
doclayoutSets
.reduce((p, set) => {