Skip to content

Commit

Permalink
fix: update callout shadows
Browse files Browse the repository at this point in the history
  • Loading branch information
vpicone committed May 7, 2019
1 parent cee7c22 commit 3aef207
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 12 deletions.
2 changes: 1 addition & 1 deletion packages/example/src/gatsby-theme-carbon/templates/Home.js
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ const customProps = {
leftText={SecondLeftText}
rightText={SecondRightText}
color="white"
backgroundColor="activePrimary"
backgroundColor="#061f80"
/>
),
};
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ const StyledGrid = styled(Grid)`
background-size: cover;
background-image: url(${props => props.image});
height: 50vh;
max-height: 560px;
width: 100%;
background-position: left bottom;
${mq.lg} {
Expand All @@ -32,7 +33,7 @@ const StyledColumn = styled(Column)`
const columCss = ({ typeStyles }) => typeStyles.quotation01;

const HomepageBanner = ({ image, renderText }) => (
<StyledGrid style={{ maxWidth: '100%', width: '100%' }} image={image}>
<StyledGrid image={image}>
<StyledRow>
<StyledColumn css={columCss}>{renderText()}</StyledColumn>
</StyledRow>
Expand Down
14 changes: 6 additions & 8 deletions packages/gatsby-theme-carbon/src/components/Homepage/Callout.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,11 @@ const StyledGrid = styled(Grid)`
background-color: ${props =>
props.theme.colors[props.backgroundColor] ||
props.backgroundColor ||
props.theme.colors.black100};
props.theme.colors.interactive02};
color: ${props =>
props.theme.colors[props.color] ||
props.color ||
props.theme.colors.black100};};
props.theme.colors.inverse01}};
width: 100%;
`;

Expand All @@ -35,6 +35,7 @@ const firstColumn = ({ typeStyles, layout }) => [
padding: '0 1rem',
paddingBottom: layout[2],
width: '100%',
fontSize: '1.5rem',
[mq.md]: {
width: '33%',
},
Expand All @@ -45,6 +46,7 @@ const secondColumn = ({ typeStyles }) => [
typeStyles.expressiveParagraph01,
{
padding: '0 1rem',
fontSize: '1.75rem',
width: '100%',
[mq.md]: {
width: '66%',
Expand All @@ -55,12 +57,8 @@ const secondColumn = ({ typeStyles }) => [
const Callout = ({ leftText, rightText, ...rest }) => (
<StyledGrid {...rest}>
<StyledRow>
<div style={{ fontSize: '1.5rem' }} css={firstColumn}>
{leftText()}
</div>
<div style={{ fontSize: '1.75rem' }} css={secondColumn}>
{rightText()}
</div>
<div css={firstColumn}>{leftText()}</div>
<div css={secondColumn}>{rightText()}</div>
</StyledRow>
</StyledGrid>
);
Expand Down
1 change: 0 additions & 1 deletion packages/gatsby-theme-carbon/src/templates/Default.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
import React from 'react';
import { WebsiteBackToTopBtn } from '@carbon/addons-website';
import styled from '@emotion/styled';
import Layout from '../components/Layout';
import PageHeader from '../components/PageHeader';
// import EditLink from '../components/EditLink';
Expand Down
2 changes: 1 addition & 1 deletion packages/gatsby-theme-carbon/src/templates/Home.js
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ Homepage.defaultProps = {
/>
),
FirstCallout: <Callout />,
SecondCallout: <Callout color="white" backgroundColor="activePrimary" />,
SecondCallout: <Callout color="inverse01" backgroundColor="#061f80" />,
};

export default Homepage;

0 comments on commit 3aef207

Please sign in to comment.