diff --git a/packages/esm-patient-common-lib/src/index.ts b/packages/esm-patient-common-lib/src/index.ts index 964c61729a..548e3d8aae 100644 --- a/packages/esm-patient-common-lib/src/index.ts +++ b/packages/esm-patient-common-lib/src/index.ts @@ -22,4 +22,3 @@ export * from './useVitalsConceptMetadata'; export * from './workspaces'; export * from './siderail-nav-button'; export * from './form-entry-interop'; -export * from './responsive-wrapper'; diff --git a/packages/esm-patient-common-lib/src/responsive-wrapper/index.ts b/packages/esm-patient-common-lib/src/responsive-wrapper/index.ts deleted file mode 100644 index 93088420b5..0000000000 --- a/packages/esm-patient-common-lib/src/responsive-wrapper/index.ts +++ /dev/null @@ -1 +0,0 @@ -export * from './responsive-wrapper.component'; diff --git a/packages/esm-patient-common-lib/src/responsive-wrapper/responsive-wrapper.component.tsx b/packages/esm-patient-common-lib/src/responsive-wrapper/responsive-wrapper.component.tsx deleted file mode 100644 index eb5fbb44a7..0000000000 --- a/packages/esm-patient-common-lib/src/responsive-wrapper/responsive-wrapper.component.tsx +++ /dev/null @@ -1,23 +0,0 @@ -import React from 'react'; -import { Layer } from '@carbon/react'; -import { useLayoutType } from '@openmrs/esm-framework'; - -type ResponsiveWrapperProps = { - children: React.ReactNode; -}; - -/** - * ResponsiveWrapper enables a responsive behavior for the component its wraps, providing a different rendering based on the current layout type. - * On desktop, it renders the children as is, while on a tablet, it wraps them in a Carbon Layer https://react.carbondesignsystem.com/?path=/docs/components-layer--overview component. - * This provides a light background for form inputs on tablets, in accordance with the design requirements. - */ -export default function ResponsiveWrapper({ children }: ResponsiveWrapperProps) { - const layout = useLayoutType(); - const isTablet = layout === 'tablet'; - - if (isTablet) { - return {children}; - } - - return <>{children}; -}