docbrown/app/javascript/onboarding/components/SlideContent.jsx
Jacob Herrington afc9351399 Onboarding a11y fixes (#4728) [deploy]
* Fix some eslint complaints

* Fix some basic a11y issues in onboarding

- Missing a main element
- TODO to enable zooming
- Rename a duplicate ID attribute

I may need some context on the zooming thing, why did we decided to
disable that in the first place? It is a pretty bad a11y issue, we will
need to fix whatever that is a workaround for instead of making it
difficult for some people to use our onboarding.

* Update screenshots
2019-11-06 12:51:13 -05:00

33 lines
616 B
JavaScript

import { h } from 'preact';
import PropTypes from 'prop-types';
const SlideContent = ({
imageSource,
imageAlt,
content,
style = { textAlign: 'center' },
}) => (
<div style={style}>
<img
src={imageSource}
alt={imageAlt}
style={{ borderRadius: '8px', height: '220px' }}
/>
<br />
{content}
<p>
<strong>
<em>Let&apos;s get started...</em>
</strong>
</p>
</div>
);
SlideContent.propTypes = {
imageSource: PropTypes.string,
imageAlt: PropTypes.string,
content: PropTypes.string,
style: PropTypes.object,
};
export default SlideContent;