Skip to content

Commit

Permalink
narratives: Change MobileNarrativeBlock id, key
Browse files Browse the repository at this point in the history
We only load one narrative block at a time in mobile view, therefore we
don't need to differentiate between div ids with a block indices.
Also remove the unnecessary `key` attribute.
  • Loading branch information
kairstenfay committed Jan 30, 2020
1 parent de7cb1b commit 5a7fb2b
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions src/components/narrative/MobileNarrativeDisplay.js
Original file line number Diff line number Diff line change
Expand Up @@ -89,9 +89,7 @@ class MobileNarrativeDisplay extends React.Component {
}
const block = this.props.blocks[this.props.currentInFocusBlockIdx];
return (
<div
id={`MobileNarrativeBlock_${this.props.currentInFocusBlockIdx}`}
key={block.__html}
<div id="MobileNarrativeBlock"
style={{
padding: "10px 20px",
height: "inherit",
Expand Down

0 comments on commit 5a7fb2b

Please sign in to comment.