Skip to content

Commit

Permalink
Fix merge conflicts
Browse files Browse the repository at this point in the history
  • Loading branch information
akmiller01 committed Jun 26, 2023
2 parents cb33c37 + 922ed18 commit 2e8ebb0
Show file tree
Hide file tree
Showing 64 changed files with 4,668 additions and 3,031 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/develop_CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,6 @@ jobs:
pull-requests: write
contents: write
steps:
- uses: fastify/github-action-merge-dependabot@v3.6
- uses: fastify/github-action-merge-dependabot@v3.9
with:
github-token: ${{secrets.GITHUB_TOKEN}}
5 changes: 4 additions & 1 deletion .vscode/extensions.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
{
"recommendations": ["johnsoncodehk.volar", "editorconfig.editorconfig"]
"recommendations": [
"vue.volar",
"editorconfig.editorconfig"
]
}
1,246 changes: 622 additions & 624 deletions cypress/fixtures/simple_q_test.json

Large diffs are not rendered by default.

487 changes: 288 additions & 199 deletions cypress/integration/advanced.spec.js

Large diffs are not rendered by default.

11 changes: 6 additions & 5 deletions cypress/integration/landing.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,15 +16,16 @@ describe('The landing view', () => {
cy.contains('IATI Unified Platform');
});

describe('search bar', () => {
it('routes a search to the simple view', () => {
describe('search bar, on search', () => {
it('shows the results view with a URL query', () => {
cy.visit('/');
cy.get('input[title=Search]').type('test');
const query = 'test';
cy.get('input[title=Search]').type(query);
cy.get('button[aria-label=Submit]').click();
cy.url().should('includes', '/simple');
cy.url().should('includes', `/?q=${query}`);
});

it('retains the search term after routing', () => {
it('retains the search term', () => {
cy.visit('/');
cy.get('input[title=Search]').type('test');
cy.get('button[aria-label=Submit]').click();
Expand Down
36 changes: 36 additions & 0 deletions cypress/integration/results.spec.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
/// <reference types="Cypress"/>

describe('The results view', () => {
it('has a visible search bar', () => {
const query = 'test';
cy.visit(`/?q=${query}`);
cy.get('[data-cy="search-input"]').should('be.visible');
});
it('has a visible button for showing the advanced search sidebar', () => {
const query = 'test';
cy.visit(`/?q=${query}`);
cy.get('[data-cy="advanced-search-results"]').should('be.visible');
});

describe('search bar', () => {
it('remains on the results view after search', () => {
const query = 'covid';
const query2 = 'test';
cy.visit(`/?q=${query}`);
cy.fixture('simple_q_test').then((simple_q_test) => {
cy.intercept(
`https://dev-api.iatistandard.org/dss/activity/search?wt=json&fl=id%2Ctitle_narrative%2Ctitle_narrative_xml_lang%2Cdescription_narrative%2Cdescription_narrative_xml_lang%2Ciati_identifier%2Clast_updated_datetime%2Creporting_org_narrative%2Cactivity_date*&start=0&rows=10&hl=true&hl.method=unified&hl.fl=*_narrative&q=${query2}&sort=score+desc`,
simple_q_test
);
cy.intercept(
`https://api.iatistandard.org/dss/activity/search?wt=json&fl=id%2Ctitle_narrative%2Ctitle_narrative_xml_lang%2Cdescription_narrative%2Cdescription_narrative_xml_lang%2Ciati_identifier%2Clast_updated_datetime%2Creporting_org_narrative%2Cactivity_date*&start=0&rows=10&hl=true&hl.method=unified&hl.fl=*_narrative&q=${query2}&sort=score+desc`,
simple_q_test
);
});
cy.get('[data-cy="search-input"]').clear();
cy.get('[data-cy="search-input"]').type(query2);
cy.get('[data-cy="search-button"]').click();
cy.url().should('includes', `/?q=${query2}`);
});
});
});
28 changes: 0 additions & 28 deletions cypress/integration/simple.spec.js

This file was deleted.

29 changes: 14 additions & 15 deletions index.html
Original file line number Diff line number Diff line change
@@ -1,18 +1,17 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<link rel="icon" href="/favicon.ico" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>IATI Datastore Search</title>
<meta name="description" content />
</head>

<head>
<meta charset="UTF-8" />
<link rel="icon" href="/favicon.ico" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>IATI Datastore Search</title>
<meta name="description" content />
</head>

<body class="font-sans text-center antialiased">
<div id="app"></div>
<div id="modals"></div>
<script type="module" src="/src/main.js"></script>
</body>

</html>
<body class="font-sans text-center antialiased">
<div id="app"></div>
<div id="modals"></div>
<div id="searchbar" class="search-bar"></div>
<script type="module" src="/src/main.js"></script>
</body>
</html>
18 changes: 14 additions & 4 deletions locale/en/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ export default {
iati_standard_website: 'IATI Standard Website',
datastore_search: 'Datastore Search',
navigation: 'Navigation',
simple_search: 'Simple Search',
simple_search: 'Search',
advanced_search: 'Advanced Search',
api: 'API',
about: 'About',
Expand Down Expand Up @@ -132,6 +132,7 @@ export default {
download_confirmation_5c: 'in an IATI Activities XML document?',
cancel: 'Cancel',
view: 'View',
view_on: 'View on',
publisher: 'Publisher',
iati_identifier: 'IATI Identifier',
last_updated: 'Last updated',
Expand All @@ -151,21 +152,23 @@ export default {
`,
advanced_unavailable_para2: `
Please
<a href="/simple" class="hover:underline text-blue-600"
<a href="/simple" class="text-underline text-blue"
>try the Simple Search</a
>
instead, or switch to a device with a larger screen.
`,
run_aria: 'Run search query with selected filters',
run: 'Run',
reset: 'Reset',
confirm_reset: 'Confirm reset',
export_aria: 'Export filters to file',
export: 'Export',
import_aria: 'Import filters from file',
import: 'Import',
add_aria: 'Add an additional filter',
add: 'Add',
add_filter: 'Add Filter',
import_filters: 'Import Filters',
add_filter: 'Build Query',
import_filters: 'Import Query',
export_filters: 'Export Filters',
export_para1: `Export currently selected filters to file?`,
export_para2: `
Expand All @@ -178,8 +181,11 @@ export default {
Advanced Search.
`,
file: 'File',
add_rule: 'Add rule',
add_group: 'Add group',
and: 'AND',
or: 'OR',
group_operator: 'Group Operator',
select_field: 'Select field',
true: 'TRUE',
false: 'FALSE',
Expand All @@ -194,6 +200,8 @@ export default {
`,
advanced: 'Advanced',
found_activities: 'Found <b>%{count}</b> activities',
results_by_advanced_search:
'Results filtered by advanced parameters. See <b>Advanced Search</b> tab for more details.',
relevance: 'Relevance',
sort_relevance_label: 'Sort results by relevance',
identifier: 'Identifier',
Expand All @@ -207,6 +215,8 @@ export default {
grouping: 'Grouping',
standard_fields: 'Standard fields',
incompatible_file_error: 'Incompatible file detected. Please try a different file.',
incompatible_file_version:
'Deprecated file version. The query can be run, but cannot be edited.',
search_term_is_required: 'Search term is required',
selection_is_required: 'Selection is required',
value_is_required: 'Value is required',
Expand Down
5 changes: 3 additions & 2 deletions locale/fr/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ export default {
iati_standard_website: 'Site Internet de la norme de l’IITA',
datastore_search: 'Datastore Search',
navigation: 'Navigation',
simple_search: 'Recherche simple',
simple_search: 'Recherche',
advanced_search: 'Recherche avancée',
api: 'API',
about: 'À propos',
Expand Down Expand Up @@ -48,6 +48,7 @@ export default {
download_confirmation_5c: 'dans un document d’activités de l’IITA au format XML ?',
cancel: 'Annuler',
view: 'Afficher',
view_on: 'Afficher sur',
publisher: 'Signataire',
iati_identifier: 'Identifiant de l’IITA',
last_updated: 'Dernière mise à jour',
Expand All @@ -64,7 +65,7 @@ export default {
advanced_unavailable_para1:
'\n La page de filtre avancé n’est malheureusement pas prise en charge par les appareils dont l’écran est trop petit.',
advanced_unavailable_para2:
'\n Veuillez <a href="/simple" class="hover:underline text-blue-600"\n >effectuer une recherche simple</a> ou utiliser un appareil doté d’un écran plus grand.',
'\n Veuillez <a href="/simple" class="text-underline text-blue"\n >effectuer une recherche simple</a> ou utiliser un appareil doté d’un écran plus grand.',
run_aria: 'Exécuter la requête de recherche avec les filtres sélectionnés',
run: 'Exécuter',
export_aria: 'Exporter les filtres vers le fichier',
Expand Down
2 changes: 1 addition & 1 deletion locale/po/datastore_search.po
Original file line number Diff line number Diff line change
Expand Up @@ -323,7 +323,7 @@ msgstr "\n La page de filtre avancé n’est malheureusement pas pris
msgid ""
"\n"
" Please\n"
" <a href=\"/simple\" class=\"hover:underline text-blue-600\"\n"
" <a href=\"/simple\" class=\"text-underline text-blue\"\n"
" >try the Simple Search</a\n"
" >\n"
" instead, or switch to a device with a larger screen.\n"
Expand Down
Loading

0 comments on commit 2e8ebb0

Please sign in to comment.