feat: implement error classification and handling for AI generation limits
- Added error classification for daily generation cap and concurrency limits in the PromptNode component, improving user feedback during AI image generation failures. - Enhanced toast notifications to provide specific messages for daily limit and concurrent job errors. - Introduced internal mutations in the credits module to check abuse limits and track usage, ensuring better resource management and user experience. - Updated AI error handling logic to categorize and respond to different error types effectively.
This commit is contained in:
@@ -103,12 +103,14 @@ export default function TextNode({ id, data, selected }: NodeProps<TextNode>) {
|
||||
/>
|
||||
) : (
|
||||
<div
|
||||
onDoubleClick={() => setIsEditing(true)}
|
||||
className="min-h-[2rem] cursor-text whitespace-pre-wrap break-words text-sm"
|
||||
onClick={() => {
|
||||
if (selected) setIsEditing(true);
|
||||
}}
|
||||
className="nodrag nowheel min-h-[2rem] cursor-text whitespace-pre-wrap break-words text-sm"
|
||||
>
|
||||
{content || (
|
||||
<span className="text-muted-foreground">
|
||||
Doppelklick zum Bearbeiten
|
||||
Auswählen, dann hier klicken
|
||||
</span>
|
||||
)}
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user