Environments in URL and better rendering

This commit is contained in:
Gregory Schier
2023-10-25 11:13:00 -07:00
parent 3b660ddbd0
commit 33c406ce49
44 changed files with 226 additions and 160 deletions

View File

@@ -1,4 +1,4 @@
import classnames from 'classnames';
import classNames from 'classnames';
import Papa from 'papaparse';
import { useMemo } from 'react';
import { useResponseBodyText } from '../../hooks/useResponseBodyText';
@@ -21,10 +21,10 @@ export function CsvViewer({ response, className }: Props) {
return (
<div className="overflow-auto h-full">
<table className={classnames(className, 'text-sm')}>
<table className={classNames(className, 'text-sm')}>
<tbody>
{parsed.data.map((row, i) => (
<tr key={i} className={classnames('border-l border-t', i > 0 && 'border-b')}>
<tr key={i} className={classNames('border-l border-t', i > 0 && 'border-b')}>
{row.map((col, j) => (
<td key={j} className="border-r px-1.5">
{col}

View File

@@ -1,5 +1,5 @@
import { convertFileSrc } from '@tauri-apps/api/tauri';
import classnames from 'classnames';
import classNames from 'classnames';
import type { HttpResponse } from '../../lib/models';
interface Props {
@@ -17,7 +17,7 @@ export function ImageViewer({ response, className }: Props) {
<img
src={src}
alt="Response preview"
className={classnames(className, 'max-w-full max-h-full')}
className={classNames(className, 'max-w-full max-h-full')}
/>
);
}