Skip to content

Commit

Permalink
Merge branch 'ohcnetwork:develop' into issues/3924/support-for-profil…
Browse files Browse the repository at this point in the history
…e-pic
  • Loading branch information
UdaySagar-Git authored Sep 20, 2024
2 parents cc51d0e + 5027d5b commit 167c2fa
Show file tree
Hide file tree
Showing 393 changed files with 10,406 additions and 14,173 deletions.
12 changes: 7 additions & 5 deletions .env
Original file line number Diff line number Diff line change
@@ -1,12 +1,14 @@
# Whitelabelling envs

REACT_APP_TITLE=CARE
REACT_APP_META_DESCRIPTION=Revolutionizing EMR with AI: Open Healthcare Network develops free, open-source tools to enhance efficiency in global healthcare delivery. Our EMR system is recognized as a Digital Public Good by the United Nations.
REACT_APP_COVER_IMAGE=https://cdn.coronasafe.network/care_logo.svg
REACT_APP_COVER_IMAGE_ALT=https://cdn.coronasafe.network/care_logo.svg
REACT_PUBLIC_URL=https://care.coronasafe.in
REACT_APP_META_DESCRIPTION="Revolutionizing EMR with AI: Open Healthcare Network develops free, open-source tools to enhance efficiency in global healthcare delivery. Our EMR system is recognized as a Digital Public Good by the United Nations."
REACT_APP_COVER_IMAGE=https://cdn.ohc.network/care_logo.svg
REACT_APP_COVER_IMAGE_ALT=https://cdn.ohc.network/care_logo.svg
REACT_PUBLIC_URL=https://care.ohc.network

# Care API URL without the /api prefix
REACT_CARE_API_URL=https://careapi.ohc.network

# Dev envs
ESLINT_NO_DEV_ERRORS=true

CARE_CDN_URL="https://egov-s3-facility-10bedicu.s3.amazonaws.com https://egov-s3-patient-data-10bedicu.s3.amazonaws.com http://localhost:4566"
1 change: 1 addition & 0 deletions .envrc
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
dotenv
test -f .env.local && dotenv .env.local
3 changes: 1 addition & 2 deletions .eslintrc.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,7 @@
"plugin:@typescript-eslint/eslint-recommended",
"plugin:@typescript-eslint/recommended",
"plugin:i18next/recommended",
"plugin:prettier/recommended",
"plugin:storybook/recommended"
"plugin:prettier/recommended"
],
"overrides": [
{
Expand Down
79 changes: 79 additions & 0 deletions .example.env
Original file line number Diff line number Diff line change
@@ -0,0 +1,79 @@
# Backend URL
REACT_CARE_API_URL=https://careapi.ohc.network

# Dashboard URL
REACT_DASHBOARD_URL=

# GitHub URL (default: https://github.com/ohcnetwork)
REACT_GITHUB_URL=

# OHCN URL (default: https://ohc.network?ref=care)
REACT_OHCN_URL=

# Plausible site domain (default: care.ohc.network)
REACT_PLAUSIBLE_SITE_DOMAIN=

# Plausible server URL (default: https://plausible.10bedicu.in)
REACT_PLAUSIBLE_SERVER_URL=


# Main logo (JSON string with light and dark properties)
REACT_HEADER_LOGO=

# Main logo (JSON string with light and dark properties)
# Example: REACT_MAIN_LOGO="{\"light\": \"https://cdn.ohc.network/light-logo.svg\", \"dark\": \"https://cdn.ohc.network/dark-logo.svg\"}"
REACT_MAIN_LOGO=

# State logo (JSON string with light and dark properties)
REACT_STATE_LOGO=

# Custom logo (JSON string with light and dark properties)
REACT_CUSTOM_LOGO=

# Custom alternative logo (JSON string with light and dark properties)
REACT_CUSTOM_LOGO_ALT=

# Custom description
REACT_CUSTOM_DESCRIPTION=

# Google Maps API key
REACT_GMAPS_API_KEY=

# Government data API key
REACT_GOV_DATA_API_KEY=

# reCAPTCHA site key
REACT_RECAPTCHA_SITE_KEY=

# Sentry DSN
REACT_SENTRY_DSN=

# Sentry environment (default: staging)
REACT_SENTRY_ENVIRONMENT=

# KASP settings
REACT_KASP_ENABLED=true
REACT_KASP_STRING=KASP
REACT_KASP_FULL_STRING=Karunya Arogya Suraksha Padhathi

# Sample format file paths
REACT_SAMPLE_FORMAT_ASSET_IMPORT=/asset-import-template.xlsx
REACT_SAMPLE_FORMAT_EXTERNAL_RESULT_IMPORT=/External-Results-Template.csv

# Camera feed, still watching idle timeout (in seconds; default: 180)
REACT_STILL_WATCHING_IDLE_TIMEOUT=

# Camera feed, still watching prompt duration (in seconds; default: 30)
REACT_STILL_WATCHING_PROMPT_DURATION=

# Feature flags
REACT_ENABLE_HCX=true
REACT_ENABLE_ABDM=true
REACT_ENABLE_SCRIBE=true
REACT_WARTIME_SHIFTING=true

# JWT token refresh interval (in milliseconds) (default: 5 minutes)
REACT_JWT_TOKEN_REFRESH_INTERVAL=

# Minimum encounter date (default: 2020-01-01)
REACT_MIN_ENCOUNTER_DATE=
2 changes: 1 addition & 1 deletion .github/CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
@@ -1 +1 @@
* @coronasafe/code-reviewers @coronasafe/care-fe-code-reviewers
* @ohcnetwork/care-fe-code-reviewers
4 changes: 2 additions & 2 deletions .github/pull_request_template.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,12 @@
- Change 2
- More?

@coronasafe/care-fe-code-reviewers @coronasafe/code-reviewers
@ohcnetwork/care-fe-code-reviewers

## Merge Checklist

- [ ] Add specs that demonstrate bug / test a new feature.
- [ ] Update [product documentation](https://docs.coronasafe.network/coronasafe-care-documentation/architecture/architecture-and-layering-of-care).
- [ ] Update [product documentation](https://docs.ohc.network).
- [ ] Ensure that UI text is kept in I18n files.
- [ ] Prep screenshot or demo video for changelog entry, and attach it to issue.
- [ ] Request for Peer Reviews
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ on:
jobs:
CodeQL-Build:
runs-on: ubuntu-latest
if: github.repository == 'coronasafe/care_fe'
if: github.repository == 'ohcnetwork/care_fe'
permissions:
security-events: write
actions: read
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/comment-p1-issues.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ on:

jobs:
add-comment:
if: github.event.label.name == 'P1' && github.repository == 'coronasafe/care_fe'
if: github.event.label.name == 'P1' && github.repository == 'ohcnetwork/care_fe'
runs-on: ubuntu-latest
permissions:
issues: write
Expand Down
21 changes: 16 additions & 5 deletions .github/workflows/cypress.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,26 +12,39 @@ on:
jobs:
cypress-run:
permissions: write-all
if: github.repository == 'coronasafe/care_fe'
if: github.repository == 'ohcnetwork/care_fe'
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
containers: [1, 2, 3, 4, 5, 6, 7, 8]
env:
REACT_CARE_API_URL: http://localhost:9000
steps:
- name: Checkout 📥
uses: actions/checkout@v3

- name: Set backend branch
id: backend-branch
run: |
if [[ '${{ github.event.pull_request.base.ref }}' == 'staging' ]]; then
echo "branch=staging" >> $GITHUB_OUTPUT
else
echo "branch=develop" >> $GITHUB_OUTPUT
fi
- name: Checkout care 📥
uses: actions/checkout@v3
with:
repository: coronasafe/care
repository: ohcnetwork/care
path: care
ref: ${{ steps.backend-branch.outputs.branch }}

- name: Start care docker containers 🐳
run: |
cd care
echo DISABLE_RATELIMIT=True >> docker/.prebuilt.env
echo "CORS_ALLOWED_ORIGINS=\"[\\\"http://localhost:4000\\\"]\"" >> docker/.prebuilt.env
make docker_config_file=docker-compose.pre-built.yaml up
make docker_config_file=docker-compose.pre-built.yaml load-dummy-data
cd ..
Expand All @@ -56,7 +69,7 @@ jobs:
- name: Install dependencies 📦
run: npm install

- name: Build & Compile rescript files ⚙️
- name: Build ⚙️
run: npm run build

- name: Install Specific Chrome Version
Expand All @@ -79,7 +92,6 @@ jobs:
parallel: true
group: "UI-Chrome"
env:
CARE_API: http://localhost:9000
CYPRESS_RECORD_KEY: ${{ secrets.CYPRESS_RECORD_KEY }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NODE_OPTIONS: --max_old_space_size=4096
Expand All @@ -101,7 +113,6 @@ jobs:
group: "UI-Chrome"
env:
CYPRESS_SPLIT_TESTS: "true"
CARE_API: http://localhost:9000
CYPRESS_RECORD_KEY: ${{ secrets.CYPRESS_RECORD_KEY }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NODE_OPTIONS: --max_old_space_size=4096
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/deploy.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ env:

jobs:
test:
if: github.repository == 'coronasafe/care_fe'
if: github.repository == 'ohcnetwork/care_fe'
runs-on: ubuntu-latest
name: Test
steps:
Expand Down
12 changes: 6 additions & 6 deletions .github/workflows/issue-automation.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,39 +10,39 @@ jobs:
issue_opened_and_reopened:
name: issue_opened_and_reopened
runs-on: ubuntu-latest
if: github.repository == 'coronasafe/care_fe' && github.event_name == 'issues' && github.event.action == 'opened' || github.event.action == 'reopened'
if: github.repository == 'ohcnetwork/care_fe' && github.event_name == 'issues' && github.event.action == 'opened' || github.event.action == 'reopened'
steps:
- name: 'Move issue to "Triage"'
uses: leonsteinhaeuser/[email protected]
with:
gh_token: ${{ secrets.PERSONAL_ACCESS_TOKEN }}
organization: coronasafe
organization: ohcnetwork
project_id: 4
resource_node_id: ${{ github.event.issue.node_id }}
status_value: "Triage"
issue_closed:
name: issue_closed
runs-on: ubuntu-latest
if: github.repository == 'coronasafe/care_fe' && github.event_name == 'issues' && github.event.action == 'closed'
if: github.repository == 'ohcnetwork/care_fe' && github.event_name == 'issues' && github.event.action == 'closed'
steps:
- name: 'Moved issue to "Done"'
uses: leonsteinhaeuser/[email protected]
with:
gh_token: ${{ secrets.PERSONAL_ACCESS_TOKEN }}
organization: coronasafe
organization: ohcnetwork
project_id: 4
resource_node_id: ${{ github.event.issue.node_id }}
status_value: "Done"
issue_assigned:
name: issue_assigned
runs-on: ubuntu-latest
if: github.repository == 'coronasafe/care_fe' && github.event_name == 'issues' && github.event.action == 'assigned'
if: github.repository == 'ohcnetwork/care_fe' && github.event_name == 'issues' && github.event.action == 'assigned'
steps:
- name: 'Move issue to "In Progress"'
uses: leonsteinhaeuser/[email protected]
with:
gh_token: ${{ secrets.PERSONAL_ACCESS_TOKEN }}
organization: coronasafe
organization: ohcnetwork
project_id: 4
resource_node_id: ${{ github.event.issue.node_id }}
status_value: "In Progress"
2 changes: 1 addition & 1 deletion .github/workflows/label-deploy-failed.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ jobs:
auto-label-deploy-failed:
runs-on: ubuntu-latest
if: |
github.repository == 'coronasafe/care_fe' && github.event.issue.pull_request &&
github.repository == 'ohcnetwork/care_fe' && github.event.issue.pull_request &&
contains(github.event.comment.body, 'Deploy Preview')
steps:
- name: Add 'Deploy-Failed'
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/label-merge-conflict.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ on:

jobs:
auto-label:
if: github.repository == 'coronasafe/care_fe'
if: github.repository == 'ohcnetwork/care_fe'
runs-on: ubuntu-latest
steps:
- uses: prince-chrismc/label-merge-conflicts-action@v2
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/label-wip.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ on:

jobs:
check-linked-issues:
if: github.repository == 'coronasafe/care_fe'
if: github.repository == 'ohcnetwork/care_fe'
name: Check linked issues
runs-on: ubuntu-latest
outputs:
Expand All @@ -29,7 +29,7 @@ jobs:
runs-on: ubuntu-latest
needs: check-linked-issues
permissions: write-all
if: github.repository == 'coronasafe/care_fe' && join(needs.check-linked-issues.outputs.linked_issues) != ''
if: github.repository == 'ohcnetwork/care_fe' && join(needs.check-linked-issues.outputs.linked_issues) != ''
steps:
- name: Label
uses: actions/github-script@v6
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/ossar-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ on:

jobs:
OSSAR-Scan:
if: github.repository == 'coronasafe/care_fe'
if: github.repository == 'ohcnetwork/care_fe'
# OSSAR runs on windows-latest.
# ubuntu-latest and macos-latest support coming soon
runs-on: windows-latest
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/stale.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ on:
jobs:
stale:
runs-on: ubuntu-latest
if: github.repository == 'coronasafe/care_fe'
if: github.repository == 'ohcnetwork/care_fe'
steps:
- uses: actions/stale@v6
with:
Expand Down
5 changes: 2 additions & 3 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -25,15 +25,14 @@ yarn-error.log*
dist
dev-dist
build
storybook-static
.swp
stats.json
public/build-meta.json
.vscode/*
!.vscode/launch.json
src/supportedBrowsers.ts


# Reason React
# Reason React
/lib/bs/**
.merlin
*.bs.js
Expand Down
3 changes: 0 additions & 3 deletions .prettierrc.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,5 @@
"arrowParens": "always",
"tailwindFunctions": [
"classNames"
],
"plugins": [
"prettier-plugin-tailwindcss"
]
}
27 changes: 0 additions & 27 deletions .storybook/main.ts

This file was deleted.

3 changes: 0 additions & 3 deletions .storybook/preview-head.html

This file was deleted.

Loading

0 comments on commit 167c2fa

Please sign in to comment.