Add styled component rule (#1261)

* Add StyledComponent rule

* update doc

* update doc

* update doc
This commit is contained in:
Weiko
2023-08-17 20:58:02 -07:00
committed by GitHub
parent 390e70a196
commit 9b34a0ff3d
70 changed files with 433 additions and 354 deletions

View File

@ -10,7 +10,7 @@ import { Activity, useUpdateActivityMutation } from '~/generated/graphql';
import { ACTIVITY_UPDATE_FRAGMENT } from '../graphql/fragments/activityUpdateFragment';
const BlockNoteStyledContainer = styled.div`
const StyledBlockNoteStyledContainer = styled.div`
width: 100%;
`;
@ -70,8 +70,8 @@ export function ActivityBodyEditor({ activity, onChange }: OwnProps) {
});
return (
<BlockNoteStyledContainer>
<StyledBlockNoteStyledContainer>
<BlockEditor editor={editor} />
</BlockNoteStyledContainer>
</StyledBlockNoteStyledContainer>
);
}

View File

@ -15,7 +15,7 @@ const meta: Meta<typeof CommentChip> = {
export default meta;
type Story = StoryObj<typeof CommentChip>;
const TestCellContainer = styled.div`
const StyledTestCellContainer = styled.div`
align-items: center;
background: ${({ theme }) => theme.background.primary};
display: flex;
@ -51,10 +51,10 @@ export const InCellDefault: Story = {
args: { count: 12 },
decorators: [
(Story) => (
<TestCellContainer>
<StyledTestCellContainer>
<StyledFakeCellText>Fake short text</StyledFakeCellText>
<Story />
</TestCellContainer>
</StyledTestCellContainer>
),
],
};
@ -63,12 +63,12 @@ export const InCellOverlappingBlur: Story = {
...InCellDefault,
decorators: [
(Story) => (
<TestCellContainer>
<StyledTestCellContainer>
<StyledFakeCellText>
Fake long text to demonstrate ellipsis
</StyledFakeCellText>
<Story />
</TestCellContainer>
</StyledTestCellContainer>
),
],
};