Skip to content

Commit

Permalink
Localize printed metadata headers
Browse files Browse the repository at this point in the history
  • Loading branch information
inukshuk committed Jul 20, 2019
1 parent e1fa810 commit 5387750
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
5 changes: 4 additions & 1 deletion src/components/print/metadata.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

const React = require('react')
const cx = require('classnames')
const { FormattedMessage } = require('react-intl')
const { auto } = require('../../format')

const {
Expand All @@ -28,7 +29,9 @@ MetadataField.propTypes = {

const MetadataSection = ({ fields, title }) => (
<section>
<h5 className="metadata-heading">{title}</h5>
<h5 className="metadata-heading">
<FormattedMessage id={title} values={{ count: 1 }}/>
</h5>
<ol className="metadata-fields">
{fields.map((f, idx) =>
<MetadataField
Expand Down
4 changes: 2 additions & 2 deletions src/components/print/photo.js
Original file line number Diff line number Diff line change
Expand Up @@ -28,10 +28,10 @@ const Photo = ({ angle, data, height, mirror, orientation, path, width }) => {
</div>
<div className="metadata-container">
<div className="col">
<MetadataSection title="Item" fields={[]}/>
<MetadataSection title="panel.metadata.item" fields={[]}/>
</div>
<div className="col">
<MetadataSection title="Photo" fields={data}/>
<MetadataSection title="panel.metadata.photo" fields={data}/>
</div>
</div>
</div>
Expand Down

0 comments on commit 5387750

Please sign in to comment.