-
Notifications
You must be signed in to change notification settings - Fork 19
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix bug, shoudl be actions refactoring a lot of stuff adding new dependencies updates, and breaking a lot of tests save off some work save some work fixed routes.js logic so it fires correctly on page load renaming files to correct slice convention renaming lintin broken references make dates strings, fixing data lens action rename query action save off some more work update tests updating more unit tests, fixing missing logic save off more work fixing broken map trends chart, updating references, fixing modal hide button in print mode save work fixing references fixing more unit tests filterSlice tests cleanup fix zip typeahead querystring save off work, fixing queryslice tests fixing data export unit tests, adding filters to query string export fixing trendsslicetest format date fix, update configurestore adding proxy middleware make app.js like complaint explorer, migrating over to new react18 strict mode, fixing bug with tour asking to exit onExit handler update app spec with realstore clean up tests, fixing percapita trends work action bar test update convert has narrative to s functional Save work trend depth toggle to functional save work update trend depth toggle update tests for company receivd filter save off product / agg branch work
- Loading branch information
1 parent
15a73db
commit 4429c20
Showing
155 changed files
with
4,962 additions
and
5,977 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,81 +1,37 @@ | ||
import './css/App.less'; | ||
import { Route, BrowserRouter as Router, Routes } from 'react-router-dom'; | ||
import { IntlProvider } from 'react-intl'; | ||
import { Provider } from 'react-redux'; | ||
import queryManager from './middleware/queryManager/queryManager'; | ||
import { ComplaintDetail } from './components/ComplaintDetail/ComplaintDetail'; | ||
import React from 'react'; | ||
import { SearchComponents } from './components/Search/SearchComponents'; | ||
import synchUrl from './middleware/synchUrl/synchUrl'; | ||
import { configureStore } from '@reduxjs/toolkit'; | ||
import aggReducer from './reducers/aggs/aggs'; | ||
import detailReducer from './reducers/detail/detail'; | ||
import mapReducer from './reducers/map/map'; | ||
import queryReducer from './reducers/query/query'; | ||
import resultsReducer from './reducers/results/results'; | ||
import routesReducer from './reducers/routes/routesSlice'; | ||
import trendsReducer from './reducers/trends/trends'; | ||
import viewReducer from './reducers/view/view'; | ||
|
||
// required format for redux-devtools-extension | ||
const store = configureStore({ | ||
devTools: true, | ||
reducer: { | ||
aggs: aggReducer, | ||
detail: detailReducer, | ||
map: mapReducer, | ||
query: queryReducer, | ||
results: resultsReducer, | ||
routes: routesReducer, | ||
trends: trendsReducer, | ||
view: viewReducer, | ||
}, | ||
middleware: (getDefaultMiddleware) => | ||
getDefaultMiddleware().concat([queryManager, synchUrl]), | ||
}); | ||
|
||
/* eslint-disable camelcase */ | ||
export const DetailComponents = () => { | ||
return ( | ||
<IntlProvider locale="en"> | ||
<main role="main"> | ||
<ComplaintDetail /> | ||
</main> | ||
</IntlProvider> | ||
); | ||
}; | ||
/* eslint-enable camelcase */ | ||
|
||
// eslint-disable-next-line react/no-multi-comp | ||
/** | ||
* Main App Component | ||
* | ||
* @returns {JSX.Element} Main app | ||
*/ | ||
export const App = () => { | ||
const App = () => { | ||
return ( | ||
<Provider store={store}> | ||
<Router> | ||
<Routes> | ||
{/* | ||
<Router> | ||
<Routes> | ||
{/* | ||
we need these duplicate routes to match relative path | ||
/data-research/consumer-complaints/search | ||
from CF.gov | ||
local | ||
which is just the root at localhost:3000/ | ||
*/} | ||
<Route index element={<SearchComponents />} /> | ||
<Route | ||
path="/data-research/consumer-complaints/search" | ||
element={<SearchComponents />} | ||
/> | ||
<Route | ||
path="/data-research/consumer-complaints/search/detail/:id" | ||
element={<DetailComponents />} | ||
/> | ||
<Route path="/detail/:id" element={<DetailComponents />} /> | ||
</Routes> | ||
</Router> | ||
</Provider> | ||
<Route index element={<SearchComponents />} /> | ||
<Route | ||
path="/data-research/consumer-complaints/search" | ||
element={<SearchComponents />} | ||
/> | ||
<Route | ||
path="/data-research/consumer-complaints/search/detail/:id" | ||
element={<ComplaintDetail />} | ||
/> | ||
<Route path="/detail/:id" element={<ComplaintDetail />} /> | ||
</Routes> | ||
</Router> | ||
); | ||
}; | ||
|
||
export default App; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.