Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

STDTC-122 apply wrappers with flow() #325

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
* Migrate to shared GA workflows. Refs STDTC-119.
* *BREAKING* Migrate stripes dependencies to their Sunflower versions. Refs STDTC-120.
* *BREAKING* Migrate `react-intl` to v7. Refs STDTC-121.
* Apply wrappers with `flow()` instead of annotations. Refs STDTC-122.

## [6.2.0](https://github.com/folio-org/stripes-data-transfer-components/tree/v6.2.0) (2024-10-30)

Expand Down
10 changes: 7 additions & 3 deletions lib/SearchAndSortPane/SearchAndSortPane.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ import queryString from 'query-string';
import { withRouter } from 'react-router-dom';
import { FormattedMessage } from 'react-intl';
import {
flow,
get,
noop,
} from 'lodash';
Expand Down Expand Up @@ -39,9 +40,7 @@ import {

import css from './SearchAndSortPane.css';

@withRouter
@withStripes
export class SearchAndSortPane extends Component {
class SearchAndSortPaneComponent extends Component {
static propTypes = {
stripes: stripesShape.isRequired,
label: PropTypes.node.isRequired,
Expand Down Expand Up @@ -427,3 +426,8 @@ export class SearchAndSortPane extends Component {
);
}
}

export const SearchAndSortPane = flow([
() => withRouter(SearchAndSortPaneComponent),
withStripes,
])();
Loading