Skip to content

Commit 486e4e7

Browse files
used monokai syntax highlighting and other cosmetic changes (#2536)
Signed-off-by: msivasubramaniaan <msivasub@redhat.com> Signed-off-by: msivasubramaniaan <msivasub@redhat.com>
1 parent d6e55d2 commit 486e4e7

File tree

2 files changed

+7
-5
lines changed

2 files changed

+7
-5
lines changed

src/webview/devfile-registry/app/cardItem.tsx

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@ import { StarterProject } from '../../../odo/componentTypeDescription';
2323
import { StarterProjectDisplay } from './starterProjectDisplay';
2424
import { Badge, Backdrop, Button, Card, CardActions, Modal } from '@material-ui/core';
2525
import { FileCopy } from '@material-ui/icons';
26+
import { monokai } from 'react-syntax-highlighter/dist/esm/styles/hljs';
2627

2728
export class CardItem extends React.Component<DevFileProps, {
2829
numOfCall: number,
@@ -280,11 +281,12 @@ export class CardItem extends React.Component<DevFileProps, {
280281
/>
281282
</CardActions>
282283
</CopyToClipboard>
283-
<SyntaxHighlighter language='yaml' useInlineStyles={false}
284+
<SyntaxHighlighter language='yaml' useInlineStyles
285+
style={monokai}
284286
wrapLines
285287
showLineNumbers
286-
lineNumberStyle={{ marginLeft: '0.5rem' }}
287-
customStyle={{ marginLeft: '-1.5rem' }}
288+
lineNumberStyle={{ marginLeft: '-1.5rem' }}
289+
customStyle={{ marginLeft: '-1.5rem', backgroundColor: 'inherit' }}
288290
codeTagProps={{
289291
style: {
290292
fontFamily: 'inherit', color: 'inherit',
@@ -316,7 +318,7 @@ export class CardItem extends React.Component<DevFileProps, {
316318
</TextContent>}
317319
</div>
318320
</CardHeader>
319-
<CardTitle style={{ margin: '1rem 1.5rem' }}>
321+
<CardTitle style={{ margin: '1.5rem' }}>
320322
<TextContent>
321323
<Text component={TextVariants.h1}>{this.props.compDescription.Devfile.metadata.displayName}</Text>
322324
</TextContent>

src/webview/devfile-registry/app/home.style.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ import { Theme, createStyles } from '@material-ui/core/styles';
88
export default (_theme: Theme) =>
99
createStyles({
1010
devfileGalleryGrid: {
11-
margin: '0rem',
11+
margin: '1.5rem 0rem',
1212
padding: '0rem 1.5rem',
1313
color: 'var(--vscode-foreground)',
1414
backgroundColor: 'var(--vscode-editor-background)',

0 commit comments

Comments
 (0)