MCPcopy Create free account
hub / github.com/Linen-dev/linen.dev / onThreadDrop

Function onThreadDrop

apps/web/ui/ChannelView/index.tsx:749–770  ·  view source on GitHub ↗
({
    source,
    target,
    from,
    to,
  }: {
    source: string;
    target: string;
    from: string;
    to: string;
  })

Source from the content-addressed store, hash-verified

747 }
748
749 function onThreadDrop({
750 source,
751 target,
752 from,
753 to,
754 }: {
755 source: string;
756 target: string;
757 from: string;
758 to: string;
759 }) {
760 if (source === 'thread' && target === 'thread') {
761 return mergeThreads({ from, to });
762 } else if (source === 'message' && target === 'thread') {
763 return moveMessageToThread({
764 messageId: from,
765 threadId: to,
766 });
767 } else if (source === 'message' && target === 'channel') {
768 return moveMessageToChannel({ messageId: from, channelId: to });
769 }
770 }
771
772 function onShare() {
773 const url =

Callers

nothing calls this directly

Calls 3

mergeThreadsFunction · 0.85
moveMessageToThreadFunction · 0.85
moveMessageToChannelFunction · 0.70

Tested by

no test coverage detected