Skip to content

Commit

Permalink
fix bug with colliding css styles
Browse files Browse the repository at this point in the history
  • Loading branch information
Dankco committed Oct 15, 2023
1 parent 4728eaa commit 72eb50e
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions src/components/CompareCode.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ SyntaxHighlighter.registerLanguage('cpp', cpp);
export default function CompareCode(props: CompareCodeProps): JSX.Element {
return (
<div className="compare">
<div className="left">
<div className="left-code">
<h1 className="caption">{props.caption1}</h1>
<SyntaxHighlighter
language="cpp"
Expand All @@ -24,7 +24,7 @@ export default function CompareCode(props: CompareCodeProps): JSX.Element {
{props.code1}
</SyntaxHighlighter>
</div>
<div className="right">
<div className="right-code">
<h1 className="caption">{props.caption2}</h1>
<SyntaxHighlighter
language="cpp"
Expand Down
4 changes: 2 additions & 2 deletions src/styles/CompareCode.scss
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,15 @@
padding: 5px;
width: 100%;

.left {
.left-code {
float: left;
left: 10%;
margin: auto;
position: relative;
width: 35%;
}

.right {
.right-code {
float: right;
margin: 10 0 10 50px;
position: relative;
Expand Down

0 comments on commit 72eb50e

Please sign in to comment.