Skip to content
Snippets Groups Projects
Unverified Commit 2eee1986 authored by Camille Villa's avatar Camille Villa Committed by GitHub
Browse files

Merge pull request #1946 from ProjectMirador/add-typography-to-metadata

adds Typography to metadata panel for themeability
parents 5be2cf57 acdb28ec
No related branches found
No related tags found
No related merge requests found
......@@ -52,15 +52,17 @@ describe('WindowSideBarInfoPanel', () => {
it('renders canvas metadata in LabelValueMetadata component', () => {
expect(
wrapper.find(LabelValueMetadata).at(0).matchesElement(
<LabelValueMetadata labelValuePairs={metadata} />,
wrapper.find(Typography).at(3).matchesElement(
<Typography>
<LabelValueMetadata labelValuePairs={metadata} />
</Typography>,
),
).toBe(true);
});
it('renders manifest label', () => {
expect(
wrapper.find(Typography).at(3).matchesElement(
wrapper.find(Typography).at(4).matchesElement(
<Typography>The Manifest Label</Typography>,
),
).toBe(true);
......@@ -68,7 +70,7 @@ describe('WindowSideBarInfoPanel', () => {
it('renders manifest description in SanitizedHtml component', () => {
expect(
wrapper.find(Typography).at(4).matchesElement(
wrapper.find(Typography).at(5).matchesElement(
<Typography>
<SanitizedHtml htmlString="The Manifest Description" ruleSet="iiif" />
</Typography>,
......@@ -78,8 +80,10 @@ describe('WindowSideBarInfoPanel', () => {
it('renders manifest metadata in LabelValueMetadata component', () => {
expect(
wrapper.find(LabelValueMetadata).at(1).matchesElement(
<LabelValueMetadata labelValuePairs={metadata} />,
wrapper.find(Typography).at(6).matchesElement(
<Typography>
<LabelValueMetadata labelValuePairs={metadata} />
</Typography>,
),
).toBe(true);
});
......
......@@ -47,7 +47,9 @@ class WindowSideBarInfoPanel extends Component {
)}
{canvasMetadata.length > 0 && (
<Typography variant="body2">
<LabelValueMetadata labelValuePairs={canvasMetadata} />
</Typography>
)}
<Divider />
......@@ -65,7 +67,9 @@ class WindowSideBarInfoPanel extends Component {
)}
{manifestMetadata.length > 0 && (
<Typography variant="body2">
<LabelValueMetadata labelValuePairs={manifestMetadata} />
</Typography>
)}
</div>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment