~bigbes/lethe

ref: b100feee542aaacd159d90f8c35b2c68a26e8893 lethe/web/src/routes/session.$tool.$host.$id.tsx -rw-r--r-- 730 bytes
b100feee — Eugene Blikh web: home route with real session list, filters, keyboard cursor a month ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
import { createFileRoute } from '@tanstack/react-router'
import React from 'react'
import { EmptyState } from '../primitives'
import { SubBar } from '../shell/SubBar'
import { Tag } from '../primitives'

export const Route = createFileRoute('/session/$tool/$host/$id')({
  component: SessionRoute,
})

function SessionRoute(): React.JSX.Element {
  const { tool, host, id } = Route.useParams()
  return (
    <>
      <SubBar>
        <Tag kind="tool">{tool}</Tag>
        <Tag kind="host">{host}</Tag>
      </SubBar>
      <div className="body body-pad">
        <EmptyState glyph="∅" copy="coming in Phase 6" />
        <div className="mono muted" style={{ marginTop: 8, fontSize: 11 }}>{id}</div>
      </div>
    </>
  )
}