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

Feature/fix country page feedbacks #691

Closed
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
92 commits
Select commit Hold shift + click to select a range
e1856c8
Restructure country pages
frozenhelium Nov 22, 2023
484df03
Add key figures and tables from country plans
barshathakuri Dec 4, 2023
38b8791
Improve styling in country page
frozenhelium Dec 4, 2023
5d68893
Add strengths and key development priorities in country strategic pri…
frozenhelium Dec 4, 2023
4c7bdf7
Add PER list to ns overview capacity in country page
frozenhelium Dec 4, 2023
5222be8
Add ns capacity in country page
frozenhelium Dec 4, 2023
d164739
Move RiskWatch to new structure
frozenhelium Dec 4, 2023
efc4b0a
feat: Add country active operations map under ongoing emergencies sec…
samshara Dec 4, 2023
072016a
feat: add active operations table to country ongoing activities
samshara Dec 6, 2023
56e31ad
Use filter styling from container in appeals table and active operati…
frozenhelium Dec 6, 2023
8d2d23b
fix: add all appeals link for country
samshara Dec 6, 2023
784b83a
Add key figure section in country page ongoing threeW activities tab
puranban Nov 30, 2023
3199221
Add emergency project map in country page ongoint threeW activities tab
puranban Dec 1, 2023
2d5e75a
Add export and view all activities in country threeW activities tab
puranban Dec 1, 2023
e118bcf
Add filter component for threeW activities in country page
puranban Dec 5, 2023
28a3919
Move threeW project components to country page ongoing activities tab
puranban Dec 4, 2023
39ebcee
Remove and update old country threeW routes
puranban Dec 5, 2023
9140c65
feat: add active operations table to country ongoing activities
samshara Dec 6, 2023
46333d4
Move threeW detail to NS Activities tab
barshathakuri Dec 5, 2023
e1e1579
Remove map and table from country plan
barshathakuri Dec 5, 2023
fc3e253
Remove keyfigures from country and Fix PR comments
barshathakuri Dec 7, 2023
d788498
Add Container in country ns ongoing
barshathakuri Dec 8, 2023
50a20fa
Move RiskWatch to new structure
frozenhelium Dec 4, 2023
61fe5ed
Add highligted operations and country key figures
barshathakuri Dec 6, 2023
ad695a8
feat: add active operations table to country ongoing activities
samshara Dec 6, 2023
737a814
feat: add national society local units map
samshara Dec 7, 2023
03e747d
feat: fetch local unit type options in filter
samshara Dec 11, 2023
63e8615
feat: add active operations table to country ongoing activities
samshara Dec 6, 2023
57cf795
Add support for assessment cycle in the country preparedness
frozenhelium Dec 6, 2023
c1af4fa
feat: add GDACS emergency events in country pages
samshara Dec 15, 2023
4dcfded
fix: typing issue for rating details
samshara Dec 15, 2023
065a021
Add directory detail in ns overview
barshathakuri Dec 15, 2023
f84e1cf
fix: use TextOutput instead of Link for source
samshara Dec 15, 2023
ee10add
fix: styling of Context and Structure tab in NS Overview Section
samshara Dec 15, 2023
6faecfd
Add NS directory contacts
barshathakuri Dec 15, 2023
40694e2
Add NS directory initiatives list
barshathakuri Dec 18, 2023
a823a82
Remove types in initiatives card
barshathakuri Dec 20, 2023
f251ce1
fix: styling for national society initiative card view
samshara Dec 20, 2023
ae4b000
Add key documents
barshathakuri Dec 20, 2023
cbe3701
Add filter and search in key documents
barshathakuri Dec 20, 2023
070985c
fix: use table to show key documents for country
samshara Dec 21, 2023
4767bee
fix: active operations table and link
samshara Dec 20, 2023
d441ba7
Add supporting partners contact
barshathakuri Dec 21, 2023
21883ba
fix: styling of supporting partners contact section
samshara Dec 21, 2023
d2fa947
Add development processes list
barshathakuri Dec 26, 2023
92e8b7f
Add List view
barshathakuri Dec 27, 2023
59644a0
Add namespace for country list item
barshathakuri Dec 28, 2023
0778e5d
fix: remove unnecessary styling
samshara Dec 28, 2023
2dd7494
Add supporting partners contact detail
barshathakuri Dec 29, 2023
46a2021
fix: use better naming on variables for supporting partner contacts
samshara Jan 4, 2024
723fd2c
Add national society indicators
barshathakuri Dec 26, 2023
ed91afc
Add national society remaining indicators
barshathakuri Dec 27, 2023
5c5059e
Add volunteers and staff count
barshathakuri Dec 27, 2023
b6bdebb
Add total staff and volunteers
barshathakuri Dec 28, 2023
359fc86
Add total youth age 6-12
barshathakuri Dec 29, 2023
8215a7f
fix: styling for national society indicators
samshara Jan 4, 2024
c8ba309
Add NS organisational capacity
barshathakuri Dec 29, 2023
1019b7c
Add NS organisational capacity description
barshathakuri Dec 29, 2023
b88d4c4
fix: show capacity information only when it is available
samshara Jan 4, 2024
7fa0633
Add Description for country pages tabs
barshathakuri Jan 2, 2024
1d34abd
fix: remove unnecessary items
samshara Jan 4, 2024
7005a4e
Add past events in country page
frozenhelium Dec 20, 2023
2632847
Remove organisation array logic
barshathakuri Jan 9, 2024
83c8542
Add country key indicators
barshathakuri Dec 28, 2023
b8ebc36
Add ifrc presence items
barshathakuri Jan 5, 2024
b8ec9fc
Fix styling and lint error
barshathakuri Jan 8, 2024
1451ea3
Add legal status link
barshathakuri Jan 8, 2024
a00c46a
Add todo comments
barshathakuri Jan 12, 2024
fea170b
fix: handle null values for country key indicators
samshara Jan 12, 2024
a7bd708
feat: create monorepo for go web app using yarn workspace
samshara Dec 29, 2023
c27fec1
fix: import warnings
samshara Jan 26, 2024
4248ab1
fix: BOCA assessment and fund_type in capacity item for national society
samshara Jan 26, 2024
dcc82c2
Add previous operations table in country previous events
frozenhelium Jan 22, 2024
7def8fe
Add country indicator
barshathakuri Jan 23, 2024
79b4479
Add location in ns local unit map
barshathakuri Jan 24, 2024
8b0d972
Add head of delegation contact
barshathakuri Jan 29, 2024
39b8535
Add icons to map legend
samshara Jan 31, 2024
e9a2d6f
Add NS income charts
frozenhelium Jan 30, 2024
bebb885
feat: add source links to data sections
samshara Feb 1, 2024
059a168
Add NS staff and volunteer disaggregations
frozenhelium Feb 1, 2024
214cafb
Add Seasonal Calendar
frozenhelium Feb 5, 2024
ff5545b
feat: implement storybook integration for @ifrc-go/ui
samshara Jan 26, 2024
9f1dbbc
feat: add story for Button component
samshara Jan 26, 2024
1480b68
Add life expectancy key indicator
barshathakuri Feb 6, 2024
88ab307
feat: integrate figma into storybook
samshara Feb 9, 2024
80bbf08
feat: document ifrc go colors
samshara Feb 9, 2024
35e2e9c
Add Stories for alert component
Feb 14, 2024
76ae55b
Add description in Alert
Feb 14, 2024
abb7d82
Add a separate hook for temporal chart data
frozenhelium Feb 9, 2024
1e1246e
Add separate hook for numeric data
frozenhelium Feb 12, 2024
022149f
Add climate chart and population map
frozenhelium Feb 19, 2024
b96c241
Remove filters from ongoing emergencies
barshathakuri Feb 27, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
103 changes: 94 additions & 9 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,83 +22,161 @@ env:
GITHUB_WORKFLOW: true

jobs:
ui:
name: UI library
environment: 'test'
runs-on: ubuntu-latest
defaults:
run:
working-directory: packages/ui
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: '18.x'
cache: 'yarn'

- name: Install dependencies on UI library
run: yarn install --frozen-lockfile

- name: Typecheck
run: yarn typecheck

- name: Lint CSS
run: yarn lint:css

- name: Lint JS
run: yarn lint:js

- name: build UI library
run: yarn build

- uses: actions/upload-artifact@v4
with:
name: ui-build
path: packages/ui/dist

test:
name: Run tests
environment: 'test'
runs-on: ubuntu-latest
needs: [ui]
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: '18.x'
cache: 'yarn'

- uses: actions/download-artifact@v4
with:
name: ui-build
path: packages/ui/dist

- name: Install dependencies
run: yarn install --prefer-offline --frozen-lockfile
run: yarn install --frozen-lockfile
working-directory: app

- name: Run test

run: yarn test
working-directory: app

translation:
name: Identify error with translation files
runs-on: ubuntu-latest
needs: [ui]
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: '18.x'
cache: 'yarn'

- uses: actions/download-artifact@v4
with:
name: ui-build
path: packages/ui/dist

- name: Install dependencies
run: yarn install --prefer-offline --frozen-lockfile
run: yarn install --frozen-lockfile
working-directory: app

- name: Identify error with translation files
run: yarn lint:translation
working-directory: app

unimported:
name: Identify unused files
runs-on: ubuntu-latest
needs: [ui]
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: '18.x'
cache: 'yarn'

- uses: actions/download-artifact@v4
with:
name: ui-build
path: packages/ui/dist

- name: Install dependencies
run: yarn install --prefer-offline --frozen-lockfile
run: yarn install --frozen-lockfile
working-directory: app

- name: Identify unused files
run: yarn lint:unused
working-directory: app

lint:
name: Lint JS
runs-on: ubuntu-latest
needs: [ui]
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: '18.x'
cache: 'yarn'

- uses: actions/download-artifact@v4
with:
name: ui-build
path: packages/ui/dist

- name: Install dependencies
run: yarn install --prefer-offline --frozen-lockfile
run: yarn install --frozen-lockfile
working-directory: app

- name: Lint JS
run: yarn lint:js
working-directory: app

lint-css:
name: Lint CSS
runs-on: ubuntu-latest
needs: [ui]
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: '18.x'
cache: 'yarn'

- uses: actions/download-artifact@v4
with:
name: ui-build
path: packages/ui/dist

- name: Install dependencies
run: yarn install --prefer-offline --frozen-lockfile
run: yarn install --frozen-lockfile
working-directory: app

- name: Lint CSS
run: yarn lint:css
working-directory: app

# FIXME: Identify a way to generate schema before we run typecheck
# typecheck:
# name: Typecheck
Expand All @@ -111,14 +189,14 @@ jobs:
# cache: 'yarn'

# - name: Install dependencies
# run: yarn install --prefer-offline --frozen-lockfile
# run: yarn install --frozen-lockfile

# - name: Typecheck
# run: yarn typecheck
build:
name: Build
environment: 'test'
needs: [lint, lint-css, test]
needs: [lint, lint-css, test, ui]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
Expand All @@ -127,8 +205,15 @@ jobs:
node-version: '18.x'
cache: 'yarn'

- uses: actions/download-artifact@v4
with:
name: ui-build
path: packages/ui/dist

- name: Install dependencies
run: yarn install --prefer-offline --frozen-lockfile
run: yarn install --frozen-lockfile
working-directory: app

- name: Build
run: yarn build
working-directory: app
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion .unimportedrc.json → app/.unimportedrc.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"#assets/content/operational_timeline_title.svg?react",
"#assets/content/operational_timeline_body.svg?react"
],
"ignoreUnused": ["@tinymce/tinymce-react"],
"ignoreUnused": ["@tinymce/tinymce-react", "@mapbox/mapbox-gl-draw"],
"extensions": [".ts", ".js", ".tsx", ".jsx"],
"aliases": {
"#generated/*": ["./generated/*"],
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
134 changes: 134 additions & 0 deletions app/eslint.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,134 @@
import { FlatCompat } from '@eslint/eslintrc';
import js from '@eslint/js';
import process from 'process';

const dirname = process.cwd();

const compat = new FlatCompat({
baseDirectory: dirname,
resolvePluginsRelativeTo: dirname,
});

const appConfigs = compat.config({
env: {
node: true,
browser: true,
es2020: true,
},
root: true,
extends: [
'airbnb',
'airbnb/hooks',
'plugin:@typescript-eslint/recommended',
'plugin:react-hooks/recommended',
],
parser: '@typescript-eslint/parser',
parserOptions: {
ecmaVersion: 'latest',
sourceType: 'module',
},
plugins: [
'@typescript-eslint',
'react-refresh',
'simple-import-sort',
'import-newlines'
],
settings: {
'import/parsers': {
'@typescript-eslint/parser': ['.ts', '.tsx']
},
'import/resolver': {
typescript: {
project: [
'./tsconfig.json',
],
},
},
},
rules: {
'react-refresh/only-export-components': 'warn',

'no-unused-vars': 0,
'@typescript-eslint/no-unused-vars': 1,

'no-use-before-define': 0,
'@typescript-eslint/no-use-before-define': 1,

'no-shadow': 0,
'@typescript-eslint/no-shadow': ['error'],

'import/no-extraneous-dependencies': [
'error',
{
devDependencies: [
'**/*.test.{ts,tsx}',
'eslint.config.js',
'postcss.config.cjs',
'stylelint.config.cjs',
'vite.config.ts',
],
optionalDependencies: false,
},
],

indent: ['error', 4, { SwitchCase: 1 }],

'import/no-cycle': ['error', { allowUnsafeDynamicCyclicDependency: true }],

'react/react-in-jsx-scope': 'off',
'camelcase': 'off',

'react/jsx-indent': ['error', 4],
'react/jsx-indent-props': ['error', 4],
'react/jsx-filename-extension': ['error', { extensions: ['.js', '.jsx', '.ts', '.tsx'] }],

'import/extensions': ['off', 'never'],

'react-hooks/rules-of-hooks': 'error',
'react-hooks/exhaustive-deps': 'warn',

'react/require-default-props': ['warn', { ignoreFunctionalComponents: true }],
'simple-import-sort/imports': 'warn',
'simple-import-sort/exports': 'warn',
'import-newlines/enforce': ['warn', 1]
},
overrides: [
{
files: ['*.js', '*.jsx', '*.ts', '*.tsx'],
rules: {
'simple-import-sort/imports': [
'error',
{
'groups': [
// side effect imports
['^\\u0000'],
// packages `react` related packages come first
['^react', '^@?\\w'],
// internal packages
['^#.+$'],
// parent imports. Put `..` last
// other relative imports. Put same-folder imports and `.` last
['^\\.\\.(?!/?$)', '^\\.\\./?$', '^\\./(?=.*/)(?!/?$)', '^\\.(?!/?$)', '^\\./?$'],
// style imports
['^.+\\.json$', '^.+\\.module.css$'],
]
}
]
}
}
]
}).map((conf) => ({
...conf,
files: ['src/**/*.tsx', 'src/**/*.jsx', 'src/**/*.ts', 'src/**/*.js'],
ignores: ['src/generated/types.ts'],
}));

const otherConfig = {
files: ['*.js', '*.ts', '*.cjs'],
...js.configs.recommended,
};

export default [
...appConfigs,
otherConfig,
];
File renamed without changes.
Loading
Loading