Skip to content

Commit

Permalink
mobile small improvement
Browse files Browse the repository at this point in the history
  • Loading branch information
andreadelrio committed Mar 26, 2020
1 parent 4776ea4 commit 9e2a095
Show file tree
Hide file tree
Showing 3 changed files with 50 additions and 9 deletions.
10 changes: 8 additions & 2 deletions src-docs/src/views/comment/comment.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -26,12 +26,18 @@ export default () => (
{body}
</EuiComment>
<EuiComment
username="mariob"
username="juanab"
type="update"
actions={copyAction}
event="pushed incident X0Z235"
timestamp="on Jan 3, 2020"
timelineIcon={<EuiAvatar size="l" name="Mario" />}
timelineIcon={
<EuiAvatar
imageUrl="https://source.unsplash.com/64x64/?woman"
size="l"
name="Juana"
/>
}
/>
<EuiComment
actions={copyAction}
Expand Down
46 changes: 40 additions & 6 deletions src/components/comment/__snapshots__/comment.test.tsx.snap
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,12 @@ exports[`EuiComment is rendered 1`] = `
>
someuser
</div>
<div
class="euiCommentEvent__headerEvent"
/>
<div
class="euiCommentEvent__headerTimestamp"
/>
</div>
<div
class="euiCommentEvent__headerActions"
Expand Down Expand Up @@ -83,7 +88,14 @@ exports[`EuiComment props event is rendered 1`] = `
>
someuser
</div>
commented
<div
class="euiCommentEvent__headerEvent"
>
commented
</div>
<div
class="euiCommentEvent__headerTimestamp"
/>
</div>
<div
class="euiCommentEvent__headerActions"
Expand Down Expand Up @@ -135,7 +147,12 @@ exports[`EuiComment props timelineIcon is rendered 1`] = `
>
someuser
</div>
<div
class="euiCommentEvent__headerEvent"
/>
<div
class="euiCommentEvent__headerTimestamp"
/>
</div>
<div
class="euiCommentEvent__headerActions"
Expand Down Expand Up @@ -182,7 +199,14 @@ exports[`EuiComment props timestamp is rendered 1`] = `
>
someuser
</div>
21 days ago
<div
class="euiCommentEvent__headerEvent"
/>
<div
class="euiCommentEvent__headerTimestamp"
>
21 days ago
</div>
</div>
<div
class="euiCommentEvent__headerActions"
Expand Down Expand Up @@ -229,7 +253,12 @@ exports[`EuiComment props type is rendered 1`] = `
>
someuser
</div>
<div
class="euiCommentEvent__headerEvent"
/>
<div
class="euiCommentEvent__headerTimestamp"
/>
</div>
<div
class="euiCommentEvent__headerActions"
Expand Down Expand Up @@ -276,7 +305,12 @@ exports[`EuiComment renders a body 1`] = `
>
someuser
</div>
<div
class="euiCommentEvent__headerEvent"
/>
<div
class="euiCommentEvent__headerTimestamp"
/>
</div>
<div
class="euiCommentEvent__headerActions"
Expand Down
3 changes: 2 additions & 1 deletion src/components/comment/comment_event.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,8 @@ export const EuiCommentEvent: FunctionComponent<EuiCommentEventProps> = ({
<div className="euiCommentEvent__header">
<div className="euiCommentEvent__headerData">
<div className="euiCommentEvent__headerUsername">{username}</div>
{event} {timestamp}
<div className="euiCommentEvent__headerEvent">{event}</div>
<div className="euiCommentEvent__headerTimestamp">{timestamp}</div>
</div>
<div className="euiCommentEvent__headerActions">{actions}</div>
</div>
Expand Down

0 comments on commit 9e2a095

Please sign in to comment.