Skip to content
Snippets Groups Projects
Commit 80bc58f3 authored by Chris Beer's avatar Chris Beer
Browse files

Add some plugin hooks

parent c0dd7a2c
No related branches found
No related tags found
No related merge requests found
...@@ -5,6 +5,7 @@ import { WindowCanvasNavigationControls } from '../../../src/components/WindowCa ...@@ -5,6 +5,7 @@ import { WindowCanvasNavigationControls } from '../../../src/components/WindowCa
import ViewerInfo from '../../../src/containers/ViewerInfo'; import ViewerInfo from '../../../src/containers/ViewerInfo';
import ViewerNavigation from '../../../src/containers/ViewerNavigation'; import ViewerNavigation from '../../../src/containers/ViewerNavigation';
import ZoomControls from '../../../src/containers/ZoomControls'; import ZoomControls from '../../../src/containers/ZoomControls';
import { PluginHook } from '../../../src/components/PluginHook';
/** create wrapper */ /** create wrapper */
function createWrapper(props) { function createWrapper(props) {
...@@ -31,6 +32,7 @@ describe('WindowCanvasNavigationControls', () => { ...@@ -31,6 +32,7 @@ describe('WindowCanvasNavigationControls', () => {
<ZoomControls zoomToWorld={zoomToWorld} /> <ZoomControls zoomToWorld={zoomToWorld} />
<ViewerNavigation /> <ViewerNavigation />
<ViewerInfo /> <ViewerInfo />
<PluginHook />
</Paper>, </Paper>,
)).toBe(true); )).toBe(true);
}); });
......
...@@ -7,7 +7,7 @@ import Img from 'react-image'; ...@@ -7,7 +7,7 @@ import Img from 'react-image';
import CompanionWindow from '../containers/CompanionWindow'; import CompanionWindow from '../containers/CompanionWindow';
import { LabelValueMetadata } from './LabelValueMetadata'; import { LabelValueMetadata } from './LabelValueMetadata';
import ns from '../config/css-ns'; import ns from '../config/css-ns';
import { PluginHook } from './PluginHook';
/** /**
* WindowSideBarInfoPanel * WindowSideBarInfoPanel
...@@ -68,6 +68,8 @@ export class AttributionPanel extends Component { ...@@ -68,6 +68,8 @@ export class AttributionPanel extends Component {
/> />
</div> </div>
)} )}
<PluginHook {...this.props} />
</CompanionWindow> </CompanionWindow>
); );
} }
......
...@@ -4,7 +4,7 @@ import Typography from '@material-ui/core/Typography'; ...@@ -4,7 +4,7 @@ import Typography from '@material-ui/core/Typography';
import CollapsibleSection from '../containers/CollapsibleSection'; import CollapsibleSection from '../containers/CollapsibleSection';
import SanitizedHtml from '../containers/SanitizedHtml'; import SanitizedHtml from '../containers/SanitizedHtml';
import { LabelValueMetadata } from './LabelValueMetadata'; import { LabelValueMetadata } from './LabelValueMetadata';
import { PluginHook } from './PluginHook';
/** /**
* CanvasInfo * CanvasInfo
...@@ -30,7 +30,6 @@ export class CanvasInfo extends Component { ...@@ -30,7 +30,6 @@ export class CanvasInfo extends Component {
id={`${id}-currentItem-${index}`} id={`${id}-currentItem-${index}`}
label={t('currentItem', { context: `${index + 1}/${totalSize}` })} label={t('currentItem', { context: `${index + 1}/${totalSize}` })}
> >
<>
{canvasLabel && ( {canvasLabel && (
<Typography <Typography
aria-labelledby={ aria-labelledby={
...@@ -53,7 +52,7 @@ export class CanvasInfo extends Component { ...@@ -53,7 +52,7 @@ export class CanvasInfo extends Component {
{canvasMetadata.length > 0 && ( {canvasMetadata.length > 0 && (
<LabelValueMetadata labelValuePairs={canvasMetadata} /> <LabelValueMetadata labelValuePairs={canvasMetadata} />
)} )}
</> <PluginHook {...this.props} />
</CollapsibleSection> </CollapsibleSection>
); );
} }
......
...@@ -4,7 +4,7 @@ import Typography from '@material-ui/core/Typography'; ...@@ -4,7 +4,7 @@ import Typography from '@material-ui/core/Typography';
import CollapsibleSection from '../containers/CollapsibleSection'; import CollapsibleSection from '../containers/CollapsibleSection';
import SanitizedHtml from '../containers/SanitizedHtml'; import SanitizedHtml from '../containers/SanitizedHtml';
import { LabelValueMetadata } from './LabelValueMetadata'; import { LabelValueMetadata } from './LabelValueMetadata';
import { PluginHook } from './PluginHook';
/** /**
* ManifestInfo * ManifestInfo
...@@ -48,6 +48,8 @@ export class ManifestInfo extends Component { ...@@ -48,6 +48,8 @@ export class ManifestInfo extends Component {
{manifestMetadata.length > 0 && ( {manifestMetadata.length > 0 && (
<LabelValueMetadata labelValuePairs={manifestMetadata} /> <LabelValueMetadata labelValuePairs={manifestMetadata} />
)} )}
<PluginHook {...this.props} />
</CollapsibleSection> </CollapsibleSection>
); );
} }
......
...@@ -5,7 +5,7 @@ import Link from '@material-ui/core/Link'; ...@@ -5,7 +5,7 @@ import Link from '@material-ui/core/Link';
import classNames from 'classnames'; import classNames from 'classnames';
import CollapsibleSection from '../containers/CollapsibleSection'; import CollapsibleSection from '../containers/CollapsibleSection';
import ns from '../config/css-ns'; import ns from '../config/css-ns';
import { PluginHook } from './PluginHook';
/** /**
* ManifestRelatedLinks * ManifestRelatedLinks
...@@ -96,6 +96,7 @@ export class ManifestRelatedLinks extends Component { ...@@ -96,6 +96,7 @@ export class ManifestRelatedLinks extends Component {
</> </>
)} )}
</dl> </dl>
<PluginHook {...this.props} />
</CollapsibleSection> </CollapsibleSection>
); );
} }
......
...@@ -6,6 +6,7 @@ import ZoomControls from '../containers/ZoomControls'; ...@@ -6,6 +6,7 @@ import ZoomControls from '../containers/ZoomControls';
import ViewerInfo from '../containers/ViewerInfo'; import ViewerInfo from '../containers/ViewerInfo';
import ViewerNavigation from '../containers/ViewerNavigation'; import ViewerNavigation from '../containers/ViewerNavigation';
import ns from '../config/css-ns'; import ns from '../config/css-ns';
import { PluginHook } from './PluginHook';
/** /**
* Represents the viewer controls in the mirador workspace. * Represents the viewer controls in the mirador workspace.
...@@ -48,6 +49,8 @@ export class WindowCanvasNavigationControls extends Component { ...@@ -48,6 +49,8 @@ export class WindowCanvasNavigationControls extends Component {
/> />
<ViewerNavigation windowId={windowId} /> <ViewerNavigation windowId={windowId} />
<ViewerInfo windowId={windowId} /> <ViewerInfo windowId={windowId} />
<PluginHook {...this.props} />
</Paper> </Paper>
); );
} }
......
...@@ -16,6 +16,7 @@ import ManifestForm from '../containers/ManifestForm'; ...@@ -16,6 +16,7 @@ import ManifestForm from '../containers/ManifestForm';
import ManifestListItem from '../containers/ManifestListItem'; import ManifestListItem from '../containers/ManifestListItem';
import MiradorMenuButton from '../containers/MiradorMenuButton'; import MiradorMenuButton from '../containers/MiradorMenuButton';
import { IIIFDropTarget } from './IIIFDropTarget'; import { IIIFDropTarget } from './IIIFDropTarget';
import { PluginHook } from './PluginHook';
/** /**
* An area for managing manifests and adding them to workspace * An area for managing manifests and adding them to workspace
...@@ -96,6 +97,7 @@ export class WorkspaceAdd extends React.Component { ...@@ -96,6 +97,7 @@ export class WorkspaceAdd extends React.Component {
) : ( ) : (
<Paper className={classes.list}> <Paper className={classes.list}>
<Typography variant="srOnly" component="h1">{t('miradorResources')}</Typography> <Typography variant="srOnly" component="h1">{t('miradorResources')}</Typography>
<PluginHook {...this.props} />
<List> <List>
{manifestList} {manifestList}
</List> </List>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment