Skip to content

Commit

Permalink
Fix layout issues
Browse files Browse the repository at this point in the history
  • Loading branch information
freshavocado7 committed Mar 20, 2024
1 parent d2226e2 commit 617986c
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 3 deletions.
2 changes: 1 addition & 1 deletion frontend/src/components/InstanceView.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ export const InstanceView = ({ templateName, objectID, endpoint }) => {
return (
<div
ref={contentRef}
className="html-content bg-white shadow-lg dark:shadow-white text-gray-700 mx-auto md:my-8 p-8 md:w-[210mm] max-w-full overflow-auto print:shadow-none print:m-0 print:p-0 print:bg-transparent"
className="html-content bg-white shadow-lg dark:shadow-white text-gray-700 mx-auto md:my-8 p-8 md:w-[210mm] max-w-full max-h-full overflow-auto print:shadow-none print:m-0 print:p-0 print:bg-transparent"
>
{details.map((item, idx) => {
if (item.type === "SVGDisplay") {
Expand Down
2 changes: 1 addition & 1 deletion frontend/src/components/Spinner.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,6 @@ import React from 'react';

export const Spinner = ({}) => (
<div className='flex justify-center items-center'>
<div className='animate-spin-slow rounded-full h-12 w-12 border-t-4 border-b-4 border-sky-500 ease-linear'></div>
<div className='animate-spin-slow rounded-full h-12 w-12 border-t-4 border-b-4 border-sky-500 ease-linear'></div>
</div>
);
2 changes: 1 addition & 1 deletion frontend/src/components/TemplateView.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ export const TemplateView = ({endpoint}) => {

{/* Main Content */}
<main className="flex-1 overflow-hidden p-4">
<div className="w-full p-4 max-w-none lg:max-w-4xl min-w-0 lg:min-w-[850px] overflow-y-auto h-full flex items-center justify-center"> {/* Ensure main content is scrollable and fills the height */}
<div className="w-full p-4 max-w-none lg:max-w-4xl min-w-0 lg:min-w-[850px] overflow-y-hidden h-full flex items-center justify-center"> {/* Ensure main content is scrollable and fills the height */}
{ !!!objectID && <p className='text-xl text-gray-700'>Select an Instance</p>}
{ objectID && <InstanceView endpoint={endpoint} objectID={objectID} templateName={templateName} /> }
</div>
Expand Down
2 changes: 2 additions & 0 deletions templates/diagrams.html.j2
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,9 @@
{% if object.nodes %}
<ul>
{% for node in object.nodes %}
{% if node.name %}
<li><a href="#{{ node.uuid }}">{{ node.name }}</a></li>
{% endif %}
{% endfor %}
</ul>
{% else %}
Expand Down

0 comments on commit 617986c

Please sign in to comment.