aboutsummaryrefslogtreecommitdiffstats
path: root/packages/dev-tools-pages/ts/components/InlineCode.tsx
diff options
context:
space:
mode:
Diffstat (limited to 'packages/dev-tools-pages/ts/components/InlineCode.tsx')
-rw-r--r--packages/dev-tools-pages/ts/components/InlineCode.tsx10
1 files changed, 8 insertions, 2 deletions
diff --git a/packages/dev-tools-pages/ts/components/InlineCode.tsx b/packages/dev-tools-pages/ts/components/InlineCode.tsx
index bfbaeb395..4b5afa95c 100644
--- a/packages/dev-tools-pages/ts/components/InlineCode.tsx
+++ b/packages/dev-tools-pages/ts/components/InlineCode.tsx
@@ -1,8 +1,14 @@
+import * as React from 'react';
import styled from 'styled-components';
import { colors } from '../variables';
-const InlineCode = styled.code`
- background-color: ${colors.blueGray}
+interface InlineCodeProps {
+ alt?: boolean;
+ children: React.ReactNode;
+}
+
+const InlineCode = styled(({ alt, children, ...props }: InlineCodeProps) => <code {...props}>{children}</code>)`
+ background-color: ${props => (props.alt ? '#E5E8E9' : colors.blueGray)};
padding: 0.1875rem;
`;