diff --git a/.circleci/config.yml b/.circleci/config.yml index 6b955479..d04937d2 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -89,8 +89,14 @@ workflows: group: "all tests" - deploy: + filters: + branches: + only: + - master requires: - - "local e2e tests" + - "checkout" +# requires: +# - "local e2e tests" # - cypress/run: # name: "deployed e2e tests" @@ -100,11 +106,11 @@ workflows: # name: Set env variables # command: | # if [ "${CIRCLE_BRANCH}" == "master" ]; then - # echo 'export CYPRESS_BASE_URL="https://iatidatastore.iatistandard.org"' >> $BASH_ENV + # echo 'export CYPRESS_BASE_URL="https://iati.cloud"' >> $BASH_ENV # elif [ "${CIRCLE_BRANCH}" == "develop" ]; then - # echo 'export CYPRESS_BASE_URL="https://store.staging.iati.cloud"' >> $BASH_ENV + # echo 'export CYPRESS_BASE_URL="https://iati.cloud"' >> $BASH_ENV # else - # echo 'export CYPRESS_BASE_URL="https://store.staging.iati.cloud"' >> $BASH_ENV + # echo 'export CYPRESS_BASE_URL="https://iati.cloud"' >> $BASH_ENV # fi # source $BASH_ENV # yarn: true diff --git a/README.md b/README.md index 373b9fcf..6c07cf1b 100644 --- a/README.md +++ b/README.md @@ -16,22 +16,21 @@ IATI is a global aid transparency standard and it makes information about aid sp ## About the project * Website: www.iati.cloud * Authors: Zimmerman -* License: AGPLv3 (see included LICENSE file for full license) -* Github Repo: github.com/zimmerman-zimmerman/query-builder-iati.cloud -* Bug Tracker: github.com/zimmerman-zimmerman/query-builder-iati.cloud/issues +* License: AGPLv3 (see included LICENSE file for full license) +* Github Repo: github.com/zimmerman-zimmerman/iati.cloud.frontend +* Bug Tracker: github.com/zimmerman-zimmerman/iati.cloud.frontend/issues ## Installing -1. Set up the iati.cloud backend first
+1. Set up the iati.cloud backend first
2. Checkout this repository to a local folder
3. Make sure you've installed node.js 10.16.3 or higher
4. Run ```yarn install```
5. Create an .env file and specify the following variables: - NODE_PATH=src/ -- REACT_APP_CLIENT_NAME=IATI Datastore +- REACT_APP_CLIENT_NAME=IATI.cloud - -6. Run yarn start +6. Run yarn start ## Documentation For a birds eye view on the different facets of the query builder please take the following steps: diff --git a/public/index.html b/public/index.html index 8b875904..a898da74 100644 --- a/public/index.html +++ b/public/index.html @@ -1,71 +1,41 @@ - - - - - - - - + + + Unlike "/favicon.ico" or "favicon.ico", "%PUBLIC_URL%/favicon.ico" will + work correctly both with client-side routing and a non-root public URL. + Learn how to configure a non-root public URL by running `npm run build`. + --> - - - + IATI.cloud + + + +
+ - + To begin the development, run `npm start` or `yarn start`. + To create a production bundle, use `npm run build` or `yarn build`. + --> + diff --git a/src/app/components/feedback/Banners/CovidBanner/index.tsx b/src/app/components/feedback/Banners/CovidBanner/index.tsx index 6b0fe5e3..6cfc5cfc 100644 --- a/src/app/components/feedback/Banners/CovidBanner/index.tsx +++ b/src/app/components/feedback/Banners/CovidBanner/index.tsx @@ -5,6 +5,7 @@ import React, { SyntheticEvent, useState, useRef } from 'react'; import { css } from 'styled-components/macro'; import useCookie from '@devhammed/use-cookie'; import { useClickAway } from 'react-use'; +import { IconChipDelete } from 'app/assets/icons/IconChipDelete'; const FontSize = '16px'; @@ -50,10 +51,12 @@ const NoticeButtonStyle = css` top: 24px; width: 24px; height: 24px; - background-size: contain; - background-position: 50%; - background-repeat: no-repeat; - background-image: url('https://iatistandard.org/assets/svg/source/icon-cross-alert.1c4f6d9acbd3.svg'); + + > svg { + path:nth-of-type(2) { + fill: #2e2e2e; + } + } `; const ParagraphStyle = css` @@ -151,28 +154,12 @@ export const CovidBanner = (props: CookieNoticeParams) => {

- Important notice: + Notice:
- Please note that the{' '} - - IATI.cloud - {' '} - does not contain data that is published in version 1 of the - Standard, or is published within a dataset which does not conform - with the{' '} - - IATI Standard Schema - + Please note that IATI.cloud does not contain data that is + published in version 1 of the Standard. IATI.cloud does contain + datasets which do not fully conform with the IATI Standard to make + as much data available as possible.

{ css={NoticeButtonStyle} data-cy="covid-banner-close-btn" aria-label="Button to close the COVID-19 banner" - /> + > + +
) diff --git a/src/app/components/inputs/selects/AsyncSelect/index.tsx b/src/app/components/inputs/selects/AsyncSelect/index.tsx index 813ba66d..4c1dec02 100644 --- a/src/app/components/inputs/selects/AsyncSelect/index.tsx +++ b/src/app/components/inputs/selects/AsyncSelect/index.tsx @@ -33,7 +33,7 @@ const customStyles = { }; async function loadOptions(search, loadedOptions, { page }, pivot) { - const url = `https://iatidatastore.iatistandard.org/search/activity?q=${pivot}:*&facet=on&facet.pivot=${pivot}&rows=0&facet.limit=15&facet.offset=${page * + const url = `https://iati.cloud/search/activity?q=${pivot}:*&facet=on&facet.pivot=${pivot}&rows=0&facet.limit=15&facet.offset=${page * 10}&facet.contains=${search.replace(/[&\/\\#,+()$~%.'":*?<>{}]/g, '')}&facet.contains.ignoreCase=true`; const response = await fetch(url); const responseJSON = await response.json(); diff --git a/src/app/components/surfaces/Footer/FooterLG.tsx b/src/app/components/surfaces/Footer/FooterLG.tsx index daad67f9..81645942 100644 --- a/src/app/components/surfaces/Footer/FooterLG.tsx +++ b/src/app/components/surfaces/Footer/FooterLG.tsx @@ -60,11 +60,11 @@ export const FooterLG = () => { - support@iatistandard.org + github@zimmerman.team @@ -72,11 +72,11 @@ export const FooterLG = () => { - @iati + @zimmerman diff --git a/src/app/components/surfaces/Footer/FooterMD.tsx b/src/app/components/surfaces/Footer/FooterMD.tsx index 4881ee23..79511ffb 100644 --- a/src/app/components/surfaces/Footer/FooterMD.tsx +++ b/src/app/components/surfaces/Footer/FooterMD.tsx @@ -59,11 +59,11 @@ export const FooterMD = () => { - support@iatistandard.org + github@zimmerman.team @@ -71,11 +71,11 @@ export const FooterMD = () => { - @iati + @zimmerman diff --git a/src/app/components/surfaces/Footer/FooterSM.tsx b/src/app/components/surfaces/Footer/FooterSM.tsx index c216a375..92a513ec 100644 --- a/src/app/components/surfaces/Footer/FooterSM.tsx +++ b/src/app/components/surfaces/Footer/FooterSM.tsx @@ -32,11 +32,11 @@ export const FooterSM = () => { - support@iatistandard.org + github@zimmerman.team @@ -44,11 +44,11 @@ export const FooterSM = () => { - @iati + @zimmerman diff --git a/src/app/modules/about-module/layout.tsx b/src/app/modules/about-module/layout.tsx index fe2bd58e..1e5cefd3 100644 --- a/src/app/modules/about-module/layout.tsx +++ b/src/app/modules/about-module/layout.tsx @@ -21,7 +21,7 @@ export const AboutLayout = () => { - {/* Appbar component needs a refactor, therefore not in this PR.*/} + {/* Appbar component needs a refactor, therefore not in this PR. */} {/* INTRODUCTION */} @@ -29,15 +29,11 @@ export const AboutLayout = () => { - IATI.cloud offers a robust online data service, - providing timely and standardised access to data published - according to the IATI Standard. Data users can gain data on - development and humanitarian resources and results through using - the{' '} - + IATI.cloud offers a robust online data service, providing timely + and standardised access to data published according to the IATI + Standard. Data users can gain data on development and + humanitarian resources and results through using the{' '} + IATI.cloud API . Users will also be able to download data from a new @@ -53,10 +49,7 @@ export const AboutLayout = () => { The new{' '} - + IATI.cloud API {' '} provides data published by organisations who have used version 2 @@ -74,8 +67,8 @@ export const AboutLayout = () => { - To help users access good quality data, IATI.cloud will not - hold any data that does not adhere to the IATI Schema. The IATI + To help users access good quality data, IATI.cloud will not hold + any data that does not adhere to the IATI Schema. The IATI Schema provides the exact order and format that publishers should provide their XML files in. More information about the Schema can be found on{' '} @@ -112,14 +105,11 @@ export const AboutLayout = () => { For detailed documentation on how to use the API, please refer to the{' '} - + IATI.cloud API documentation - . For information on how to map queries from the ‘classic’ Datastore - to the new one, please see the{' '} + . For information on how to map queries from the ‘classic’ + Datastore to the new one, please see the{' '} { The{' '} Query builder @@ -150,7 +140,7 @@ export const AboutLayout = () => {
For guidance on how to use the query builder, see the{' '} Query Builder User Guide. @@ -165,12 +155,12 @@ export const AboutLayout = () => {
- The benefit of IATI.cloud is that you can convert the - original IATI data, provided in XML format, into three - formats - CSV, XLM and JSON. All data in IATI.cloud is filtered - and output based on IATI activities. The exception is converting - the data into CSV format, which also allows you to output it - based on budgets and transactions. + The benefit of IATI.cloud is that you can convert the original + IATI data, provided in XML format, into three formats - CSV, XML + and JSON. All data in IATI.cloud is filtered and output based on + IATI activities. The exception is converting the data into CSV + format, which also allows you to output it based on budgets and + transactions. @@ -180,19 +170,19 @@ export const AboutLayout = () => { - XML - returns the original activity XML as - published. This is enhanced with metadata, specifying the - version of the IATI standard that individual activities were - published at, as well as details of the query result. + XML - returns the original activity XML as published. This is + enhanced with metadata, specifying the version of the IATI + standard that individual activities were published at, as well + as details of the query result. - CSV - will convert the published XML data into CSV - format. Only a subset of published data is present. This format - can be used to analyse information using spreadsheet software - such as Microsoft Excel or Libreoffice Calc. + CSV - will convert the published XML data into CSV format. Only + a subset of published data is present. This format can be used + to analyse information using spreadsheet software such as + Microsoft Excel or Libreoffice Calc. @@ -209,10 +199,10 @@ export const AboutLayout = () => { - JSON - IATI.cloud will convert the published XML to JSON - format. All the original published information is present in - this alternative format. The same metadata that is given in the - XML output is available in the JSON output. + JSON - IATI.cloud will convert the published XML to JSON format. + All the original published information is present in this + alternative format. The same metadata that is given in the XML + output is available in the JSON output.
@@ -220,7 +210,7 @@ export const AboutLayout = () => {
- + ); diff --git a/src/app/modules/common/ModuleHeader/index.tsx b/src/app/modules/common/ModuleHeader/index.tsx index 011ecae7..162e62b2 100644 --- a/src/app/modules/common/ModuleHeader/index.tsx +++ b/src/app/modules/common/ModuleHeader/index.tsx @@ -36,7 +36,7 @@ export const ModuleHeader = (props: ModuleModel) => { For guidance on how
to use the query builder, see the{' '} Query Builder User Guide. diff --git a/src/app/modules/documentation-module/common/DocDetail/common/ApiCallFragment/index.tsx b/src/app/modules/documentation-module/common/DocDetail/common/ApiCallFragment/index.tsx index 7d3c9791..d22b9c01 100644 --- a/src/app/modules/documentation-module/common/DocDetail/common/ApiCallFragment/index.tsx +++ b/src/app/modules/documentation-module/common/DocDetail/common/ApiCallFragment/index.tsx @@ -28,7 +28,7 @@ export const ApiCallFragment = (data) => { const clipboard = useClipboard({ copiedTimeout: 600 }); const parsed = data.data; const { request } = parsed; - const targetURL = 'https://iatidatastore.iatistandard.org'; + const targetURL = 'https://iati.cloud' const showRequest = useStoreActions((actions) => actions.request.showRequest); diff --git a/src/app/modules/documentation-module/common/DocDetail/common/DocCallPreview/common/RequestExample/code.ts b/src/app/modules/documentation-module/common/DocDetail/common/DocCallPreview/common/RequestExample/code.ts index e532a634..df21d278 100644 --- a/src/app/modules/documentation-module/common/DocDetail/common/DocCallPreview/common/RequestExample/code.ts +++ b/src/app/modules/documentation-module/common/DocDetail/common/DocCallPreview/common/RequestExample/code.ts @@ -2,7 +2,7 @@ export const codes = { code: `var https = require('https'); var options = { 'method': 'GET', - 'hostname': 'iatidatastore.iatistandard.org', + 'hostname': 'iati.cloud', 'path': '/api/activities/?has_other_identifier=True&fields=title%2Cother_identifier&format=json', 'headers': { } diff --git a/src/app/modules/documentation-module/common/DocDetail/common/DocCallPreview/common/RequestExample/index.tsx b/src/app/modules/documentation-module/common/DocDetail/common/DocCallPreview/common/RequestExample/index.tsx index 8ba524bf..d3c76f13 100644 --- a/src/app/modules/documentation-module/common/DocDetail/common/DocCallPreview/common/RequestExample/index.tsx +++ b/src/app/modules/documentation-module/common/DocDetail/common/DocCallPreview/common/RequestExample/index.tsx @@ -61,7 +61,7 @@ export const RequestExample = () => { url.raw.replace( '{{url}}', '' - // 'https://iatidatastore.iatistandard.org' + // 'https://iati.cloud"' )} diff --git a/src/app/modules/documentation-module/common/DocDetail/common/DocCallPreview/common/RequestResponse/index.tsx b/src/app/modules/documentation-module/common/DocDetail/common/DocCallPreview/common/RequestResponse/index.tsx index da1966a5..34ddad33 100644 --- a/src/app/modules/documentation-module/common/DocDetail/common/DocCallPreview/common/RequestResponse/index.tsx +++ b/src/app/modules/documentation-module/common/DocDetail/common/DocCallPreview/common/RequestResponse/index.tsx @@ -37,7 +37,7 @@ export const RequestResponse = () => { const moddedURL = url.raw.replace( '{{url}}', - 'https://iatidatastore.iatistandard.org' + 'https://iati.cloud' ); const [request, response] = useFetch(moddedURL); diff --git a/src/app/modules/documentation-module/state/model.ts b/src/app/modules/documentation-module/state/model.ts index 6c773099..12267648 100644 --- a/src/app/modules/documentation-module/state/model.ts +++ b/src/app/modules/documentation-module/state/model.ts @@ -1,11 +1,11 @@ -//cc:api documentation module#; state - model +// cc:api documentation module#; state - model import { action, Action } from 'easy-peasy'; import { Endpoint } from 'app/state/interfaces/Endpoint'; import { ApiModel } from 'app/state/api'; export const fetchPostmanDatas: Endpoint = (params: RequestInit = {}) => fetch( - `https://iatidatastore.iatistandard.org/static/postman/${process.env.REACT_APP_DOC_FILENAME}`, + `https://iati.cloud/static/postman/${process.env.REACT_APP_DOC_FILENAME}`, { method: 'GET', ...params, @@ -125,5 +125,3 @@ export interface SubCategory3Model { request: RequestModel; description?: string; } - -////////////////////////////////// diff --git a/src/app/modules/documentation-module/state/service.ts b/src/app/modules/documentation-module/state/service.ts index dce24ee3..2d783f56 100644 --- a/src/app/modules/documentation-module/state/service.ts +++ b/src/app/modules/documentation-module/state/service.ts @@ -1,9 +1,6 @@ import { Endpoint } from 'app/state/interfaces/Endpoint'; export const getPostmanData: Endpoint = (params: RequestInit = {}) => - fetch( - 'https://iatidatastore.iatistandard.org/static/postman/postman_json.json', - { - method: 'GET', - } - ).then((res) => res.json()); + fetch('https://iati.cloud/static/postman/postman_json_iati_cloud.json', { + method: 'GET', + }).then((res) => res.json()); diff --git a/src/app/modules/landing-module/common/LandingMidSection.tsx b/src/app/modules/landing-module/common/LandingMidSection.tsx index 0f64d929..a5f40900 100644 --- a/src/app/modules/landing-module/common/LandingMidSection.tsx +++ b/src/app/modules/landing-module/common/LandingMidSection.tsx @@ -11,8 +11,8 @@ export const LandingMidSection = () => { { - IATI Datastore + IATI.cloud - The IATI Datastore provides data on development and humanitarian + IATI.cloud provides data on development and humanitarian spending and projects that address poverty and crises across the world. @@ -39,7 +39,7 @@ export const LandingLayout = () => { - Access data through using the Datastore’s API or Query Builder. + Access data through using IATI.cloud's API or Query Builder. diff --git a/src/app/modules/notfound-module/index.tsx b/src/app/modules/notfound-module/index.tsx index f774c635..70100df9 100644 --- a/src/app/modules/notfound-module/index.tsx +++ b/src/app/modules/notfound-module/index.tsx @@ -5,6 +5,6 @@ import { PageNotFoundLayout } from './layout'; import { useTitle } from 'react-use'; export function PageNotFound() { - useTitle('IATI Datastore - 404 Page not found'); + useTitle('IATI.cloud - 404 Page not found'); return ; } diff --git a/src/app/modules/notfound-module/layout.tsx b/src/app/modules/notfound-module/layout.tsx index c8bd75d0..01fc5d5f 100644 --- a/src/app/modules/notfound-module/layout.tsx +++ b/src/app/modules/notfound-module/layout.tsx @@ -15,7 +15,7 @@ export const PageNotFoundLayout = () => { {/* Appbar component needs a refactor, therefore not in this PR.*/} - {/* What can I do with the IATI Datastore? */} + {/* What can I do with IATI.cloud? */}
{
- {/* What can I do with the IATI Datastore? */} + {/* What can I do with IATI.cloud?? */} { error image - {/* What can I do with the IATI Datastore? */} + {/* What can I do with IATI.cloud?? */} {
@@ -197,7 +197,7 @@ export const DownloadFragment = () => {
@@ -237,7 +237,7 @@ export const DownloadFragment = () => { ? queryState.replace('json', `xslt&tr=${rowFormat}-xml.xsl`) : queryState.replace('json', 'xml') } - fileName={`iatidatastore-iatistandard-${filename()}.xml`} + fileName={`IATIcloud-${filename()}.xml`} /> diff --git a/src/app/modules/querybuilder-module/index.tsx b/src/app/modules/querybuilder-module/index.tsx index 8f646fa7..389c5f28 100644 --- a/src/app/modules/querybuilder-module/index.tsx +++ b/src/app/modules/querybuilder-module/index.tsx @@ -10,7 +10,7 @@ import { ModuleStore } from './state/store'; function QueryBuilderModule() { /* set the window title */ - useTitle('IATI Datastore - Query Builder'); + useTitle('IATI.cloud - Query Builder'); /* instantiate the layout*/ return ( diff --git a/src/app/modules/querybuilder-module/layout.tsx b/src/app/modules/querybuilder-module/layout.tsx index 92c6cd4b..2cf7ded1 100644 --- a/src/app/modules/querybuilder-module/layout.tsx +++ b/src/app/modules/querybuilder-module/layout.tsx @@ -53,7 +53,7 @@ export const QueryBuilderLayout = () => { {/* module header */} diff --git a/src/app/state/api/index.ts b/src/app/state/api/index.ts index bc9b373c..ee9454d6 100755 --- a/src/app/state/api/index.ts +++ b/src/app/state/api/index.ts @@ -4,7 +4,7 @@ import { Action, action, computed, Computed, Thunk, thunk } from 'easy-peasy'; import { Endpoint } from 'app/state/interfaces/Endpoint'; export const baseURL = - 'https://iatidatastore.iatistandard.org/search/activity?'; + 'https://iati.cloud/search/activity?'; // export const baseURL = // 'https://test-datastore.iatistandard.org/search/activity?'; @@ -18,7 +18,7 @@ const NODE_ENV = 'production'; export const HOSTNAME = // @ts-ignore - NODE_ENV === 'development' ? '/' : 'https://iatidatastore.iatistandard.org/'; // 'https://iatidatastore.iatistandard.org/'; + NODE_ENV === 'development' ? '/' : 'https://iati.cloud/'; // 'https://iatidatastore.iatistandard.org/'; // datastore.iati.cloud