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

(feat) Various UI mods #119

Merged
merged 3 commits into from
Aug 23, 2024
Merged

(feat) Various UI mods #119

merged 3 commits into from
Aug 23, 2024

Conversation

denniskigen
Copy link
Member

@denniskigen denniskigen commented Aug 22, 2024

Requirements

  • This PR has a title that briefly describes the work done, including the ticket number if there is a ticket.
  • My work conforms to the OpenMRS 3.0 Styleguide and design documentation.
  • My work includes tests or is validated by existing tests.

Summary

This PR applies various UI refactors to the Medication Dispensing UI, including:

  • Fixing the thick border between the table rows (by setting display: none on the collapsed TableExpandedRow).
  • Fixing the double top border on the pagination container of the datatable.
  • Adding an empty state to the DataTable when the search term doesn't yield any matching prescriptions.
  • Fixing the translation string in the Prescription details Allergies tile to account for plurals.

Other changes include:

  • Enabling linting for stylesheets (an oversight from the past). This explains the large diff owing from running Prettier on all the stylesheets.
  • Enabling linting for tests

Screenshots

Before

CleanShot 2024-08-22 at 11  53 43@2x

CleanShot 2024-08-23 at 12  00 45@2x

CleanShot 2024-08-23 at 12  02 48@2x

After

CleanShot 2024-08-22 at 11  53 56@2x

CleanShot 2024-08-23 at 12  01 12@2x

CleanShot 2024-08-23 at 12  03 07@2x

Related Issue

Other

required
/>
)}
<Stack gap={5}>
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is for consistent spacing between the form elements.

</Layer>
</div>
)}
{prescriptionsTableRows?.length > 0 && (
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So the pagination container is hidden in the empty state.

Copy link
Member

@mogoodrich mogoodrich left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @denniskigen !

It's hard for me to review with all the formatting changes, but I trust you... :)

Why all the formatting changes, is yarn lint not set up properly?

@ibacher
Copy link
Member

ibacher commented Aug 23, 2024

Why all the formatting changes, is yarn lint not set up properly?

I think it mostly derives from the fact that we used to have prettier ignore most things that weren't Typescript files, and we've been changing things so that we use it to reformat Sass files as well.

@mogoodrich
Copy link
Member

I think it mostly derives from the fact that we used to have prettier ignore most things that weren't Typescript files, and we've been changing things so that we use it to reformat Sass files as well.

Ah, right, I'm seeing that now... thanks @denniskigen !

@denniskigen denniskigen merged commit 2b1c517 into main Aug 23, 2024
4 checks passed
@denniskigen denniskigen deleted the feat/ui-mods branch August 23, 2024 17:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants