Merged
Conversation
…in ProjectPage feat: Implement DeploymentPage with sidebar navigation and query editor
kigiri
reviewed
Sep 22, 2025
web/components/Filtre.tsx
Outdated
| // f{prefix}c1=..., f{prefix}o1=..., f{prefix}v1=... | ||
| type FilterRow = { idx: number; key: string; op: string; value: string } | ||
|
|
||
| const filterOperators = ['=', '!=', '>', '>=', '<', '<=', 'contains'] as const |
Member
There was a problem hiding this comment.
= -> eq
!= -> neq
> -> gt
>= -> gte
< -> lt
<= -> lte
kigiri
reviewed
Sep 22, 2025
web/components/Filtre.tsx
Outdated
| @@ -0,0 +1,290 @@ | |||
| // URL filter schema (prefix = 't' | 'l'): | |||
| // f{prefix}c0=key, f{prefix}o0=op, f{prefix}v0=value | |||
Member
There was a problem hiding this comment.
// ft=name,eq,patrick
// ft=id,gte,10
// ft=name,neq,martin
// fl=name,like,pat%rick
const tableFilters = urlSearchParams.getAll('ft')
const logFilters = urlSearchParams.getAll('fl')
Member
There was a problem hiding this comment.
const str = 'name,neq,martin'
const first = str.indexOf(',')
const second = str.indexOf(',', first + 1)
const key = str.slice(0, first)
const op = str.slice(first + 1, second)
const query = str.slice(second + 1)
kigiri
reviewed
Sep 22, 2025
web/pages/DeploymentPage.tsx
Outdated
| <div class='m-0 p-2 text-xs font-mono text-base-content/50 leading-6 text-right'> | ||
| {Array.from({ | ||
| length: Math.max(1, (query.match(/\n/g)?.length ?? 0) + 1), | ||
| }).map((_, i) => <div key={i}>{i + 1}</div>)} |
Member
There was a problem hiding this comment.
Array(Math.max(1, (query.match(/\n/g)?.length ?? 0) + 1))
.keys().map(i => <div key={i}>{i + 1}</div>).toArray()
kigiri
reviewed
Sep 22, 2025
web/pages/DeploymentPage.tsx
Outdated
| activeTab = 'tables', | ||
| }: { activeTab?: 'tables' | 'queries' | 'logs' }) { | ||
| const tabClass = (t: 'tables' | 'queries' | 'logs') => | ||
| `tab ${activeTab === t ? 'tab-active' : ''}` |
Member
There was a problem hiding this comment.
(
<A params={{ tab }} role='tab' class={`tab ${activeTab === tab ? 'tab-active' : ''} capitalize`}>
{tab}
</A>
)Verify the css tailwind class for capitalized
kigiri
reviewed
Sep 22, 2025
web/pages/DeploymentPage.tsx
Outdated
| export const DeploymentPage = () => { | ||
| const tab = url.params.tab || 'tables' | ||
| if (!['tables', 'queries', 'logs'].includes(tab)) { | ||
| navigate({ params: { tab: 'tables' } }) |
Member
There was a problem hiding this comment.
replace: true in this navigate no ?
kigiri
reviewed
Sep 22, 2025
web/pages/ProjectPage.tsx
Outdated
| </> | ||
| ) | ||
| if (!project.pending && !project.data) { | ||
| navigate({ href: '/projects', params: undefined }) |
59265aa to
855ff40
Compare
…and enhance URL parameter handling in router
855ff40 to
df009d1
Compare
kigiri
reviewed
Sep 29, 2025
web/pages/DeploymentPage.tsx
Outdated
|
|
||
| export function QueryEditor() { | ||
| const query = url.params.q || '' | ||
| const results = [] as AnyRecord[] |
kigiri
reviewed
Sep 29, 2025
web/pages/DeploymentPage.tsx
Outdated
| > | ||
| <span class='text-sm'>Entries</span> | ||
| <ChevronsDown class='h-4 w-4' /> | ||
| </button> |
Member
There was a problem hiding this comment.
either add action to button or just remove it
kigiri
reviewed
Sep 29, 2025
web/pages/DeploymentPage.tsx
Outdated
| role='tab' | ||
| class={`tab ${activeTab === t ? 'tab-active' : ''}`} | ||
| > | ||
| {t.charAt(0).toUpperCase() + t.slice(1)} |
Member
There was a problem hiding this comment.
and should be mouved outside this comp to be it's own component
kigiri
reviewed
Sep 29, 2025
web/pages/DeploymentPage.tsx
Outdated
| > | ||
| {tab('tables')} | ||
| {tab('queries')} | ||
| {tab('logs')} |
Member
There was a problem hiding this comment.
<TabButton tabName='tables' />
<TabButton tabName='queries' />
<TabButton tabName='logs' />
kigiri
reviewed
Sep 29, 2025
web/pages/DeploymentPage.tsx
Outdated
|
|
||
| const safeFormatTimestamp = (timestamp: string) => { | ||
| const d = new Date(timestamp) | ||
| if (isNaN(d.getTime())) return timestamp |
Member
There was a problem hiding this comment.
Sure we don't want Number.isNaN() here ? usually the one we want
kigiri
reviewed
Sep 29, 2025
web/pages/DeploymentPage.tsx
Outdated
| minute: '2-digit', | ||
| second: '2-digit', | ||
| fractionalSecondDigits: 3, | ||
| }) |
…Page and Filtre components
d4f6bd8 to
24e96b2
Compare
kigiri
approved these changes
Oct 3, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.