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

Fixes UI Bug Issue in Symptom Editor #9270

Merged
Merged
Show file tree
Hide file tree
Changes from 21 commits
Commits
Show all changes
34 commits
Select commit Hold shift + click to select a range
e4e065c
Fix dropdown icon and placeholder issue
JavidSumra Nov 30, 2024
481337a
Merge branch 'develop' of https://github.com/JavidSumra/care_fe into …
JavidSumra Dec 2, 2024
a2f82c1
Fix in Symptom Eitor Bug
JavidSumra Dec 2, 2024
4099e86
Remove Unnecessary Changes
JavidSumra Dec 2, 2024
ed94362
Merge branch 'develop' into issues/8998/symptoms-editor-fix
JavidSumra Dec 2, 2024
a594ebf
Merge branch 'develop' into issues/8998/symptoms-editor-fix
JavidSumra Dec 4, 2024
9f8e7e7
Merge branch 'develop' of https://github.com/JavidSumra/care_fe into …
JavidSumra Dec 4, 2024
76277e9
Add Code Rabbit Suggestions
JavidSumra Dec 4, 2024
b04adaf
Merge branch 'issues/8998/symptoms-editor-fix' of https://github.com/…
JavidSumra Dec 4, 2024
ef59197
Merge branch 'develop' into issues/8998/symptoms-editor-fix
JavidSumra Dec 4, 2024
b8833fb
Fix failing test suit
JavidSumra Dec 4, 2024
2e126ee
Merge branch 'issues/8998/symptoms-editor-fix' of https://github.com/…
JavidSumra Dec 4, 2024
5692925
Merge branch 'develop' into issues/8998/symptoms-editor-fix
JavidSumra Dec 4, 2024
6e29157
Merge branch 'develop' of https://github.com/JavidSumra/care_fe into …
JavidSumra Dec 4, 2024
8feb1c2
Merge branch 'develop' into issues/8998/symptoms-editor-fix
JavidSumra Dec 4, 2024
5dc4943
Merge branch 'develop' of https://github.com/JavidSumra/care_fe into …
JavidSumra Dec 5, 2024
d4d42a7
Merge branch 'develop' into issues/8998/symptoms-editor-fix
JavidSumra Dec 5, 2024
dc859e7
Merge branch 'develop' into issues/8998/symptoms-editor-fix
JavidSumra Dec 9, 2024
32082d3
Merge branch 'develop' into issues/8998/symptoms-editor-fix
JavidSumra Dec 9, 2024
bd8739d
Fix Failing Test suit
JavidSumra Dec 9, 2024
e43492e
Merge branch 'issues/8998/symptoms-editor-fix' of https://github.com/…
JavidSumra Dec 9, 2024
be7cefa
Fix Failing Test case
JavidSumra Dec 9, 2024
e0e2637
Merge branch 'develop' into issues/8998/symptoms-editor-fix
JavidSumra Dec 9, 2024
376915b
Merge branch 'develop' of https://github.com/JavidSumra/care_fe into …
JavidSumra Dec 11, 2024
025929d
Fix UI Issue
JavidSumra Dec 11, 2024
2512243
Merge branch 'issues/8998/symptoms-editor-fix' of https://github.com/…
JavidSumra Dec 11, 2024
1c8b5f0
Revert Changes
JavidSumra Dec 11, 2024
46da85f
Merge branch 'develop' into issues/8998/symptoms-editor-fix
JavidSumra Dec 11, 2024
97024dc
Merge branch 'develop' into issues/8998/symptoms-editor-fix
JavidSumra Dec 11, 2024
666c9c0
Merge branch 'develop' into issues/8998/symptoms-editor-fix
JavidSumra Dec 11, 2024
0fa012b
Merge branch 'develop' into issues/8998/symptoms-editor-fix
JavidSumra Dec 13, 2024
ca7ae33
Merge branch 'develop' into issues/8998/symptoms-editor-fix
JavidSumra Dec 13, 2024
e8bd966
Merge branch 'develop' into issues/8998/symptoms-editor-fix
JavidSumra Dec 14, 2024
7649566
Merge branch 'develop' into issues/8998/symptoms-editor-fix
JavidSumra Dec 16, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 2 additions & 4 deletions cypress/support/commands.ts
Original file line number Diff line number Diff line change
Expand Up @@ -191,12 +191,10 @@ Cypress.Commands.add("selectRadioOption", (name: string, value: string) => {
Cypress.Commands.add("clickAndTypeDate", (selector, date) => {
cy.get(selector).scrollIntoView();
cy.get(selector).click();
cy.get('[data-test-id="date-input"]:visible [data-time-input]').each((el) =>
cy.get('[id="date-input"]:visible [data-time-input]').each((el) =>
cy.wrap(el).clear(),
);
cy.get(`[data-test-id="date-input"]:visible [data-time-input="0"]`)
.click()
.type(date);
cy.get(`[id="date-input"]:visible [data-time-input="0"]`).click().type(date);
cy.get("body").click(0, 0);
});

Expand Down
1 change: 1 addition & 0 deletions src/components/Common/DateInputV2.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -331,6 +331,7 @@ const DateInputV2: React.FC<Props> = ({
data-scribe-ignore
className={`cui-input-base cursor-pointer disabled:cursor-not-allowed ${className}`}
placeholder={placeholder ?? t("select_date")}
title={placeholder}
value={value ? dayjs(value).format(dateFormat) : ""}
/>
<div className="absolute right-0 top-1/2 -translate-y-1/2 p-2">
Expand Down
2 changes: 1 addition & 1 deletion src/components/Common/DateTextInput.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ export default function DateTextInput(props: {
e.target === e.currentTarget &&
(value ? goToInput(allowTime ? 4 : 2) : goToInput(0))
}
data-test-id="date-input"
id="date-input"
JavidSumra marked this conversation as resolved.
Show resolved Hide resolved
>
{Object.entries(editingText)
.slice(0, allowTime ? 5 : 3)
Expand Down
8 changes: 5 additions & 3 deletions src/components/Form/FormFields/AutocompleteMultiselect.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -171,16 +171,18 @@ export const AutocompleteMutliSelect = <T, V>(
{!props.disabled && (
<ComboboxButton
ref={comboButtonRef}
className="absolute inset-y-0 right-0 flex items-center pr-2"
className="absolute inset-y-0 right-0 flex items-center justify-center pr-2"
>
<div className="absolute right-0 top-1 mr-2 flex items-center text-lg text-secondary-900">
<div
className={`relative flex items-center justify-center text-lg text-secondary-900 ${value.some((val: any) => val.option) ? "-top-5" : ""}`}
>
{props.isLoading ? (
<CareIcon icon="l-spinner" className="animate-spin" />
) : (
<CareIcon
id="dropdown-toggle"
icon="l-angle-down"
className="-mb-1.5"
className="text-lg"
/>
)}
</div>
Expand Down
5 changes: 4 additions & 1 deletion src/components/Form/FormFields/DateFormField.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,10 @@ const DateFormField = (props: Props) => {
return (
<FormField field={field}>
<DateInputV2
className={classNames(field.error && "border-red-500")}
className={classNames(
field.error && "border-red-500",
"mr-9 text-ellipsis ",
)}
containerClassName={props.containerClassName}
id={field.id}
name={field.name}
Expand Down
4 changes: 2 additions & 2 deletions src/components/Form/ModelCrudEditor.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ export default function ModelCrudEditor<TRes extends Identifier, TReq, TErr>(
}, [item]);

return (
<div className="flex w-full flex-col items-center gap-4 md:flex-row">
<div className="flex w-full flex-col gap-4 md:flex-row">
{children(item, setItem, processing, errors)}
{props.type === "creating" && (
<ButtonV2
Expand All @@ -120,7 +120,7 @@ export default function ModelCrudEditor<TRes extends Identifier, TReq, TErr>(
onClick={() => handleDelete(props.item.id)}
className="w-full text-xl text-red-500 hover:text-red-700 disabled:grayscale md:w-auto"
>
<CareIcon icon="l-times-circle" />{" "}
<CareIcon icon="l-times-circle" />
<span className="text-sm md:hidden">{t("remove")}</span>
</button>
)}
Expand Down
Loading
Loading