feat: created Grading page (#557)

This commit is contained in:
Peter Kulko
2023-08-14 21:44:01 +03:00
committed by GitHub
parent 484b141328
commit f9bc5c4927
77 changed files with 3521 additions and 94 deletions

View File

@@ -0,0 +1,12 @@
.section-sub-header {
display: flex;
justify-content: space-between;
align-items: center;
margin-bottom: .75rem;
border-bottom: $border-width solid $light-400;
h2 {
color: $black;
margin-bottom: .75rem;
}
}

View File

@@ -0,0 +1,16 @@
import React from 'react';
import { render } from '@testing-library/react';
import SectionSubHeader from '.';
const props = {
title: 'foo-title',
description: 'bar-description',
};
describe('<SectionSubHeader />', () => {
it('renders successfully', () => {
const { getByText } = render(<SectionSubHeader {...props} />);
expect(getByText(props.title)).toBeInTheDocument();
expect(getByText(props.description)).toBeInTheDocument();
});
});

View File

@@ -0,0 +1,20 @@
import React from 'react';
import PropTypes from 'prop-types';
const SectionSubHeader = ({ title, description }) => (
<header className="section-sub-header">
<h2 className="lead">{title}</h2>
<span className="small text-gray-700">{description}</span>
</header>
);
SectionSubHeader.defaultProps = {
description: '',
};
SectionSubHeader.propTypes = {
title: PropTypes.string.isRequired,
description: PropTypes.string,
};
export default SectionSubHeader;