Skip to content

Commit

Permalink
Merge branch 'develop'
Browse files Browse the repository at this point in the history
  • Loading branch information
fleischie committed Jul 23, 2018
2 parents 05e8e25 + 277402e commit 14aa8cc
Show file tree
Hide file tree
Showing 2 changed files with 36 additions and 1 deletion.
2 changes: 1 addition & 1 deletion after/syntax/javascript.vim
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,7 @@ syn match cssError contained "{@<>"
syn match jsTaggedTemplate extend
\ "\<css\>\|\<keyframes\>\|\<injectGlobal\>\|\<fontFace\>"
\ nextgroup=styledDefinition
syn match jsFuncCall "\<styled\>\s*(\k\+)"
syn match jsFuncCall "\<styled\>\s*(.\+)" transparent
\ nextgroup=styledDefinition
syn match jsFuncCall "\<styled\>\s*(\%('\k\+'\|\"\k\+\"\|`\k\+`\))"
\ contains=styledTagNameString
Expand Down
35 changes: 35 additions & 0 deletions examples/issue-44.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
import styled from 'styled-components';

const Schedule = styled.div`
display: none;
`;

Schedule.Part = styled.div`
align-items: center;
display: flex;
`;

const Something = styled(Link)`
align-items: center;
display: none;
`;

function test() {
return styled.div;
}

Schedule.CourseTimes = styled(test())`
align-items: flex-start;
img {
margin-top: 0.3rem;
}
`;

Schedule.CourseTimes = styled(Schedule.Part)`
align-items: flex-start;
img {
margin-top: 0.3rem;
}
`;

0 comments on commit 14aa8cc

Please sign in to comment.