Skip to content

Commit

Permalink
* fix naming and type errors
Browse files Browse the repository at this point in the history
  • Loading branch information
CalamityC committed Oct 17, 2023
1 parent 754df1d commit 4d9a256
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 10 deletions.
2 changes: 1 addition & 1 deletion lib/DocumentFilter/DocumentFilterField.js
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ const DocumentFilterField = ({ atTypeValues, index, name }) => {

DocumentFilterField.propTypes = {
atTypeValues: PropTypes.arrayOf(PropTypes.object),
index: PropTypes.string,
index: PropTypes.number,
name: PropTypes.string,
};

Expand Down
1 change: 0 additions & 1 deletion lib/DocumentFilter/DocumentFilterRule.js
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,6 @@ const DocumentFilterRule = ({

DocumentFilterRule.propTypes = {
ariaLabelledby: PropTypes.string.isRequired,
clearRuleValue: PropTypes.func.isRequired,
index: PropTypes.number.isRequired,
name: PropTypes.string.isRequired,
onDelete: PropTypes.func.isRequired,
Expand Down
6 changes: 3 additions & 3 deletions lib/DocumentFilter/SupplementaryDocumentFilter.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ import {

import DocumentFilterForm from './DocumentFilterForm';

const DocumentFilter = ({ activeFilters, atTypeValues, filterHandlers }) => {
const SupplementaryDocumentFilter = ({ activeFilters, atTypeValues, filterHandlers }) => {
const [editingFilters, setEditingFilters] = useState(false);
const openEditModal = () => setEditingFilters(true);
const closeEditModal = () => setEditingFilters(false);
Expand Down Expand Up @@ -124,10 +124,10 @@ const DocumentFilter = ({ activeFilters, atTypeValues, filterHandlers }) => {
);
};

DocumentFilter.propTypes = {
SupplementaryDocumentFilter.propTypes = {
activeFilters: PropTypes.object,
atTypeValues: PropTypes.arrayOf(PropTypes.object),
filterHandlers: PropTypes.object,
};

export default DocumentFilter;
export default SupplementaryDocumentFilter;
9 changes: 4 additions & 5 deletions lib/DocumentFilter/SupplementaryDocumentFilterRule.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ import { Field } from 'react-final-form';
import { required as requiredValidator } from '../validators';
import DocumentFilterRuleConstants from './DocumentFilterRuleConstants';

const DocumentFilterRule = ({
const SupplementaryDocumentFilterRule = ({
ariaLabelledby,
atTypeValues,
index,
Expand Down Expand Up @@ -128,10 +128,9 @@ const DocumentFilterRule = ({
);
};

DocumentFilterRule.propTypes = {
SupplementaryDocumentFilterRule.propTypes = {
ariaLabelledby: PropTypes.string.isRequired,
atTypeValues: PropTypes.object.isRequired,
clearRuleValue: PropTypes.func.isRequired,
atTypeValues: PropTypes.arrayOf(PropTypes.object),
index: PropTypes.number.isRequired,
name: PropTypes.string.isRequired,
onDelete: PropTypes.func.isRequired,
Expand All @@ -142,4 +141,4 @@ DocumentFilterRule.propTypes = {
}),
};

export default DocumentFilterRule;
export default SupplementaryDocumentFilterRule;

0 comments on commit 4d9a256

Please sign in to comment.