Files
image-studio/view/GenerateSheet.tsx
syntaxbullet 5915c62a9a refactor: Update bottom controls for improved styling and functionality
- Adjusted button styles across various components for consistency and better UX.
- Enhanced layout of action controls to utilize whitespace more effectively.
- Updated slider styles for a more modern appearance and improved usability.
- Refined input fields and labels for better accessibility and readability.
- Introduced new app surface styles for a cohesive design across the application.
- Added tests for canvas cursor behavior to ensure correct cursor display during operations.
2026-07-11 14:55:32 +02:00

31 lines
1.1 KiB
TypeScript

import type { GenerateSettings } from "@editor/tools";
import type { AppStore } from "@editor/store";
import type { GenerationResourcesState } from "@editor/state";
import { GenerateControls } from "./bottom-controls/GenerateControls";
export type GenerateSheetProps = {
settings: GenerateSettings;
resources: GenerationResourcesState;
open: boolean;
dispatch: AppStore["dispatch"];
};
export function GenerateSheet({ settings, resources, open, dispatch }: GenerateSheetProps) {
return (
<aside
id="generate-sheet"
aria-hidden={!open}
aria-label="Generate settings"
className={`app-surface pointer-events-auto absolute bottom-3 right-3 top-[4.5rem] z-20 flex w-[22rem] max-w-[calc(100vw-1.5rem)] flex-col overflow-hidden rounded-xl px-3 text-sm text-white transition-all duration-200 ${
open ? "translate-x-0 opacity-100" : "pointer-events-none translate-x-8 opacity-0"
}`}
>
{open ? (
<div className="subtle-scrollbar min-h-0 flex-1 overflow-auto py-4">
<GenerateControls settings={settings} resources={resources} dispatch={dispatch} />
</div>
) : null}
</aside>
);
}