{/* show screenshot image */}
{customMessage &&
typeof customMessage === 'string' &&
customMessage.startsWith('data:image') && (
)}
{/* show parts of the message */}
{message?.parts?.map((part, i) => (
))}
{/* show React payload e.g. LLM Model Configure Panel when it is a valid React element */}
{customMessage && React.isValidElement(customMessage) && (
{customMessage}
)}
{/* show error message if any */}
{hasFailed && }