Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/common/latex/latex_images.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ export function LatexImageX({ node, source }: LatexNodeProps<LatexMacroImage>) {
};

// eslint-disable-next-line @next/next/no-img-element, jsx-a11y/alt-text -- pre-existing error before eslint inclusion
return <img style={style} className="max-w-full" src={src} />;
return <img style={style} className="max-w-full inline-block" src={src} />;
}


Expand Down
6 changes: 3 additions & 3 deletions src/common/latex/latex_render.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -240,23 +240,23 @@ function LatexNodeEnvironmentX({ node, source }: LatexNodeProps<LatexNodeEnviron
// (it would be arranged vertically by the flex-col)
return (
<div className="flex flex-col items-center text-center">
<div className="w-full">
<div className="max-w-full">
{renderEnvironmentContent(node, source)}
</div>
</div>
);
case "flushright":
return (
<div className="flex flex-col items-right text-right">
<div className="w-full">
<div className="max-w-full">
{renderEnvironmentContent(node, source)}
</div>
</div>
);
case "flushleft":
return (
<div className="flex flex-col items-left text-left">
<div className="w-full">
<div className="max-w-full">
{renderEnvironmentContent(node, source)}
</div>
</div>
Expand Down
30 changes: 30 additions & 0 deletions src/db/scripts/data/batch-demo.tex
Original file line number Diff line number Diff line change
Expand Up @@ -82,3 +82,33 @@ \section*{Gibberish}
You can also nest all of these together. \href{http://example.com}{\HUGE{\sout{\tt{\bf\it{{link}}}}}}

Here is a picture for your troubles \includegraphics{/tasks/batch-demo/attachments/path/to/chocolate-hills.jpg}

Now let me test some stuff with center!

\begin{center}
\includegraphics[scale=0.5]{/tasks/batch-demo/attachments/path/to/chocolate-hills.jpg}
\end{center}


\begin{center}
Some veeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeery looooooooooooooooooooooooooooooooooooooooong \textbf{text} here

\includegraphics[scale=0.5]{/tasks/batch-demo/attachments/path/to/chocolate-hills.jpg}


Some veeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeery looooooooooooooooooooooooooooooooooooooooong \textbf{text} here
\end{center}

\begin{center}
short \textbf{text} here

\includegraphics[scale=0.5]{/tasks/batch-demo/attachments/path/to/chocolate-hills.jpg}


short \textbf{text} here
\end{center}


\begin{center}
short \textbf{text} here
\end{center}