16 lines
479 B
TypeScript
16 lines
479 B
TypeScript
import type { ImageResponse } from 'shared/types';
|
|
|
|
export function imageToMarkdown(image: ImageResponse): string {
|
|
return ``;
|
|
}
|
|
|
|
export function appendImageMarkdown(
|
|
prev: string,
|
|
image: ImageResponse
|
|
): string {
|
|
const markdownText = imageToMarkdown(image);
|
|
if (prev.trim() === '') return markdownText + '\n';
|
|
const needsNewline = !prev.endsWith('\n');
|
|
return prev + (needsNewline ? '\n' : '') + markdownText + '\n';
|
|
}
|