A few fixes

This commit is contained in:
Gregory Schier
2023-04-04 13:31:48 -07:00
parent 54310983a3
commit 0ffe459a8b
5 changed files with 18 additions and 14 deletions

View File

@@ -71,7 +71,7 @@ export function GraphQLEditor({ defaultValue, onChange, baseRequest, ...extraEdi
const dialog = useDialog();
return (
<div className="pb-2 h-full grid grid-rows-[minmax(0,100%)_auto_auto_minmax(0,auto)]">
<div className="pb-2 h-full w-full grid grid-cols-1 grid-rows-[minmax(0,100%)_auto_auto_minmax(0,auto)]">
<Editor
contentType="application/graphql"
defaultValue={query ?? ''}

View File

@@ -84,6 +84,9 @@ export const ResponsePane = memo(function ResponsePane({ style, className }: Pro
[activeResponse?.headers, toggleViewMode, viewMode],
);
// Don't render until we know the view mode
if (viewMode === undefined) return null;
return (
<div
style={style}

View File

@@ -15,7 +15,7 @@ export function StatusTag({ asBackground, response, className }: Props) {
<span
className={classnames(
className,
'text-white bg-opacity-90',
'text-white bg-opacity-90 dark:bg-opacity-50',
status >= 0 && status < 100 && 'bg-red-600',
status >= 100 && status < 200 && 'bg-yellow-600',
status >= 200 && status < 300 && 'bg-green-600',