diff --git a/packages/esm-cervical-cancer-app/src/api/types.ts b/packages/esm-cervical-cancer-app/src/api/types.ts deleted file mode 100644 index 3e7212b17..000000000 --- a/packages/esm-cervical-cancer-app/src/api/types.ts +++ /dev/null @@ -1,71 +0,0 @@ -export interface LocationData { - display: string; - uuid: string; -} - -export interface SessionData { - authenticated: boolean; - locale: string; - currentProvider: { - uuid: string; - display: string; - person: DisplayMetadata; - identifier: string; - attributes: Array<{}>; - retired: boolean; - links: Links; - resourceVersion: string; - }; - sessionLocation: { - uuid: string; - display: string; - name: string; - description?: string; - }; - user: { - uuid: string; - display: string; - username: string; - }; - privileges: Array; - roles: Array; - retired: false; - links: Links; -} - -type Links = Array<{ - rel: string; - uri: string; -}>; - -type DisplayMetadata = { - display?: string; - links?: Links; - uuid?: string; -}; - -export interface Location { - uuid: string; - display: string; - name: string; - description?: string; - address1?: string; - address2?: string; - cityVillage?: string; - stateProvince?: string; - country?: string; - postalCode?: string; - latitude?: string; - longitude?: string; - countryDistrict?: string; - address3?: string; - address4?: string; - address5?: string; - address6?: string; -} - -export interface Concept { - uuid: string; - display: string; - answers?: Concept[]; -} diff --git a/packages/esm-cervical-cancer-app/src/index.ts b/packages/esm-cervical-cancer-app/src/index.ts index cc9533508..a279be22e 100644 --- a/packages/esm-cervical-cancer-app/src/index.ts +++ b/packages/esm-cervical-cancer-app/src/index.ts @@ -2,8 +2,8 @@ import { defineConfigSchema, getSyncLifecycle } from '@openmrs/esm-framework'; import { caCxSummaryDashboardMeta, caCxVisitsDashboardMeta, cervicalCancerFolderMeta } from './dashboard.meta'; import { createDashboardLink } from '@openmrs/esm-patient-common-lib'; import { createConditionalDashboardGroup } from '@ohri/openmrs-esm-ohri-commons-lib'; -import CacxSummaryList from './views/cacx-summary/cacx-summary.component'; -import CacxVisitServices from './views/cacx-visits/cacx-visits-services.component'; +import CacxSummaryList from './cervical-cancer/cacx-summary/cacx-summary.component'; +import CacxVisitServices from './cervical-cancer/cacx-visits/cacx-visits-services.component'; import { configSchema } from './config-schema'; export const importTranslation = require.context('../translations', false, /.json$/, 'lazy'); diff --git a/packages/esm-cervical-cancer-app/src/views/cacx-summary/cacx-summary.component.tsx b/packages/esm-cervical-cancer-app/src/views/cacx-summary/cacx-summary.component.tsx deleted file mode 100644 index 9cec36db4..000000000 --- a/packages/esm-cervical-cancer-app/src/views/cacx-summary/cacx-summary.component.tsx +++ /dev/null @@ -1,21 +0,0 @@ -import React, { useEffect, useState } from 'react'; -import { useTranslation } from 'react-i18next'; -import { EmptyStateComingSoon } from '@ohri/openmrs-esm-ohri-commons-lib'; - -interface CacxSummaryListProps { - patientUuid: string; -} - -const CacxSummaryList: React.FC = ({ patientUuid }) => { - const { t } = useTranslation(); - - const headerTitle = t('cacxSummary', 'CaCx Summary'); - - return ( - <> - - - ); -}; - -export default CacxSummaryList; diff --git a/packages/esm-cervical-cancer-app/src/views/cacx-visits/cacx-config.json b/packages/esm-cervical-cancer-app/src/views/cacx-visits/cacx-config.json deleted file mode 100644 index 76d4bf0b8..000000000 --- a/packages/esm-cervical-cancer-app/src/views/cacx-visits/cacx-config.json +++ /dev/null @@ -1,115 +0,0 @@ -{ - "menuId": "cervicalCancer", - "tabDefinitions": [ - { - "tabName": "CaCx Registration", - "headerTitle": "CaCx Registration", - "displayText": "CaCx Registration", - "encounterType": "cacxRegistrationEncounterType_UUID", - "columns": [ - { - "id": "screeningDate", - "isDate": true, - "title": "Visit Date", - "concept": "cervicalCancerScreeningDateConcept" - }, - { - "id": "previouslyScreened", - "title": "Previously Screened for CaCx", - "concept": "previouslyScreenedConcept" - }, - { - "id": "eligibleforScreening", - "title": "Eligible for CaCx Screening", - "concept": "eligibleForScreeningConcept" - }, - { - "id": "actions", - "title": "Actions", - "actionOptions": [ - { - "formName": "cervicalCancerRegistrationForm", - "package": "cervical-cancer", - "label": "View Details", - "mode": "view" - }, - { - "formName": "cervicalCancerRegistrationForm", - "package": "cervical-cancer", - "label": "Edit Form", - "mode": "edit" - } - ] - } - ], - "launchOptions": { - "displayText": "Add", - "moduleName": "@ohri/openmrs-esm-ohri-cervical-cancer-app" - }, - "formList": [ - { - "name": "cervicalCancerRegistrationForm", - "uuid": "cervicalCancerRegistrationFormUuid" - } - ] - }, - { - "tabName": "CaCx Treatment", - "headerTitle": "CaCx Treatment", - "displayText": "CaCx Treatment", - "encounterType": "cacxTreatmentEncounterType_UUID", - "columns": [ - { - "id": "encounterDate", - "isDate": true, - "title": "Visit Date", - "concept": "cacxEncounterDateConcept" - }, - { - "id": "screeningMethod", - "title": "Screening Method", - "concept": "screeningMethodConcept" - }, - { - "id": "screeningResult", - "title": "Screening Results", - "multipleConcepts": ["colopsyResultsConcept", "humanPapilomaVirusResultsConcept","papanicolaouSmearResultsConcept", "VIAProcedureResultsConcept"], - "useMultipleObs": true - }, - { - "id": "cacxTreatment", - "title": "CaCx Treatment", - "concept": "cacxTreatmentConcept" - }, - { - "id": "actions", - "title": "Actions", - "actionOptions": [ - { - "formName": "screeningAndCancerTreatmentForm", - "package": "cervical-cancer", - "label": "View Details", - "mode": "view" - }, - { - "formName": "screeningAndCancerTreatmentForm", - "package": "cervical-cancer", - "label": "Edit Forms", - "mode": "edit" - } - ] - } - ], - "launchOptions": { - "displayText": "Add", - "moduleName": "@ohri/openmrs-esm-ohri-cervical-cancer-app" - }, - "formList": [ - { - "name": "screeningAndCancerTreatmentForm", - "uuid": "screeningAndCancerTreatmentFormUuid" - } - ] - } - ] -} diff --git a/packages/esm-cervical-cancer-app/src/views/cacx-visits/cacx-visits-services.component.tsx b/packages/esm-cervical-cancer-app/src/views/cacx-visits/cacx-visits-services.component.tsx deleted file mode 100644 index 29039051a..000000000 --- a/packages/esm-cervical-cancer-app/src/views/cacx-visits/cacx-visits-services.component.tsx +++ /dev/null @@ -1,45 +0,0 @@ -import React from 'react'; -import { Tabs, Tab, TabList, TabPanels, TabPanel } from '@carbon/react'; -import { useConfig } from '@openmrs/esm-framework'; -import { EncounterList, getMenuItemTabConfiguration } from '@ohri/openmrs-esm-ohri-commons-lib'; -import cacxConfigSchema from './cacx-config.json'; - -import styles from '../common.scss'; - -interface OverviewListProps { - patientUuid: string; -} - -const CaCxCervicalCancerServices: React.FC = ({ patientUuid }) => { - const config = useConfig(); - const tabs = getMenuItemTabConfiguration(cacxConfigSchema, config); - - return ( -
- - - {tabs.map((tab) => ( - {tab.name} - ))} - - - {tabs.map((tab) => ( - - - - ))} - - -
- ); -}; - -export default CaCxCervicalCancerServices; diff --git a/packages/esm-cervical-cancer-app/src/views/common.scss b/packages/esm-cervical-cancer-app/src/views/common.scss deleted file mode 100644 index fd5ede633..000000000 --- a/packages/esm-cervical-cancer-app/src/views/common.scss +++ /dev/null @@ -1,39 +0,0 @@ -@use '@carbon/styles/scss/spacing'; -@import '../root.scss'; - -.widgetContainer { - background-color: $ui-background; -} - -.widgetHeaderContainer { - display: flex; - justify-content: space-between; - align-items: center; - padding: spacing.$spacing-04 0 spacing.$spacing-04 spacing.$spacing-05; -} - -.widgetHeaderContainer > h4:after { - content: ''; - display: block; - width: 2rem; - padding-top: 0.188rem; - border-bottom: 0.375rem solid var(--brand-01); -} - -.toggleButtons { - width: fit-content; - margin: 0 spacing.$spacing-03; -} - -.tabContainer div[role='tabpanel'] { - padding: 0 !important; -} - -.tabContainer li button { - width: 100% !important; - } - - - .hivStatusTag { - min-width: 80px; - } diff --git a/packages/esm-covid-app/src/covid/patient chart/case-assessment-schema-config.json b/packages/esm-covid-app/src/covid/patient-chart/case-assessment-schema-config.json similarity index 100% rename from packages/esm-covid-app/src/covid/patient chart/case-assessment-schema-config.json rename to packages/esm-covid-app/src/covid/patient-chart/case-assessment-schema-config.json diff --git a/packages/esm-covid-app/src/covid/patient chart/case-assessment.component.tsx b/packages/esm-covid-app/src/covid/patient-chart/case-assessment.component.tsx similarity index 100% rename from packages/esm-covid-app/src/covid/patient chart/case-assessment.component.tsx rename to packages/esm-covid-app/src/covid/patient-chart/case-assessment.component.tsx diff --git a/packages/esm-covid-app/src/covid/patient chart/common.scss b/packages/esm-covid-app/src/covid/patient-chart/common.scss similarity index 100% rename from packages/esm-covid-app/src/covid/patient chart/common.scss rename to packages/esm-covid-app/src/covid/patient-chart/common.scss diff --git a/packages/esm-covid-app/src/covid/patient chart/covid-vaccinations-schema.json b/packages/esm-covid-app/src/covid/patient-chart/covid-vaccinations-schema.json similarity index 100% rename from packages/esm-covid-app/src/covid/patient chart/covid-vaccinations-schema.json rename to packages/esm-covid-app/src/covid/patient-chart/covid-vaccinations-schema.json diff --git a/packages/esm-covid-app/src/covid/patient chart/covid-vaccinations.component.tsx b/packages/esm-covid-app/src/covid/patient-chart/covid-vaccinations.component.tsx similarity index 100% rename from packages/esm-covid-app/src/covid/patient chart/covid-vaccinations.component.tsx rename to packages/esm-covid-app/src/covid/patient-chart/covid-vaccinations.component.tsx diff --git a/packages/esm-covid-app/src/covid/patient chart/lab-results-schema-config.json b/packages/esm-covid-app/src/covid/patient-chart/lab-results-schema-config.json similarity index 100% rename from packages/esm-covid-app/src/covid/patient chart/lab-results-schema-config.json rename to packages/esm-covid-app/src/covid/patient-chart/lab-results-schema-config.json diff --git a/packages/esm-covid-app/src/covid/patient chart/lab-results.component.tsx b/packages/esm-covid-app/src/covid/patient-chart/lab-results.component.tsx similarity index 100% rename from packages/esm-covid-app/src/covid/patient chart/lab-results.component.tsx rename to packages/esm-covid-app/src/covid/patient-chart/lab-results.component.tsx diff --git a/packages/esm-covid-app/src/index.ts b/packages/esm-covid-app/src/index.ts index 5704b2d2e..93f65014f 100644 --- a/packages/esm-covid-app/src/index.ts +++ b/packages/esm-covid-app/src/index.ts @@ -1,7 +1,7 @@ import { defineConfigSchema, getSyncLifecycle } from '@openmrs/esm-framework'; -import CovidVaccinations from './covid/patient chart/covid-vaccinations.component'; -import CovidLabResults from './covid/patient chart/lab-results.component'; -import CovidAssessment from './covid/patient chart/case-assessment.component'; +import CovidVaccinations from './covid/patient-chart/covid-vaccinations.component'; +import CovidLabResults from './covid/patient-chart/lab-results.component'; +import CovidAssessment from './covid/patient-chart/case-assessment.component'; import { covidAssessmentsDashboardMeta, covidLabTestsDashboardMeta,