Files
supabase/apps/database-new/components/AllThreadsModal/MessageNode.tsx
Jonathan Summers-Muir 7abc9d24c4 Chore/more server actions (#19379)
* First

* Fix the parsing of SQL.

* Get thread data action

* Remove old page

* Wait for data to complete

* SSR everywhere

* Remove unused

* Add monaco settings

* update loaders

* Add sorting

* supress hydration warnings

* Fix profile layout

* more server action action

* fixes

* Update page.tsx

* Update actions.ts

* Update AssistantChatForm.tsx

* init

* add polling

* Update actions.ts

* redirect to message id

* Update page.tsx

* Update page.tsx

* handle run loading states with use client state with valtio

* reduce first load JS

* test action v1

* test action v2

* server action test 3

* test action 4

* test action 5

* test 6

* test 7

* test 7

* test 8

* test 9

* test 10

* test 11

* TEST 12

* TEST 13

* try and make it work

* Update page.tsx

* Update actions.ts

* redirect added in

* Update page.tsx

* Update SchemaFlow.tsx

* Update SchemaFlowHandler.tsx

* 14

* Update SchemaFlow.tsx

* move parse tables to client

* a11y fixes

---------

Co-authored-by: Terry Sutton <saltcod@gmail.com>
Co-authored-by: Ivan Vasilov <vasilov.ivan@gmail.com>
2023-12-03 21:01:14 -03:30

45 lines
1.3 KiB
TypeScript

// import { Handle, NodeProps, Position } from 'reactflow'
// import { NODE_HEIGHT, NODE_WIDTH } from './AllThreadsModal.constants'
// export interface MessageNodeData {
// id: string
// text: string
// isStart: boolean
// isEnd: boolean
// onSelectMessage: () => void
// }
// const MessageNode = ({ data }: NodeProps<MessageNodeData>) => {
// const { id, text, isStart, isEnd, onSelectMessage } = data
// return (
// <>
// {!isStart && (
// <Handle
// type="target"
// id="handle-t"
// position={Position.Top}
// style={{ background: 'transparent' }}
// />
// )}
// <div
// className="flex flex-col gap-y-1 rounded bg-surface-100 border border-default p-3 hover:bg-surface-200 transition cursor-pointer"
// style={{ width: NODE_WIDTH / 2 - 10, height: NODE_HEIGHT / 2 }}
// onClick={() => onSelectMessage()}
// >
// <p className="text-xs text-foreground-light font-mono">{id}</p>
// <p className="text-sm">{text}</p>
// </div>
// {!isEnd && (
// <Handle
// type="source"
// id="handle-s"
// position={Position.Bottom}
// style={{ background: 'transparent' }}
// />
// )}
// </>
// )
// }
// export default MessageNode