diff --git a/.github/workflows/cypress.yaml b/.github/workflows/cypress.yaml index 0f588568bbc..1104d7f480d 100644 --- a/.github/workflows/cypress.yaml +++ b/.github/workflows/cypress.yaml @@ -1,8 +1,6 @@ name: Cypress Tests on: - schedule: - - cron: "30 22 * * *" pull_request: branches: - develop @@ -17,7 +15,7 @@ jobs: strategy: fail-fast: false matrix: - containers: [1, 2, 3, 4, 5, 6, 7, 8] + containers: [1, 2, 3, 4] env: REACT_CARE_API_URL: http://localhost:9000 steps: @@ -136,4 +134,4 @@ jobs: if: steps.pr_origin.outputs.is_forked == 'true' with: name: cypress-videos - path: cypress/videos + path: cypress/videos \ No newline at end of file diff --git a/cypress/pageobject/Users/UserSearch.ts b/cypress/pageobject/Users/UserSearch.ts index d72c00c0de7..1292395fce3 100644 --- a/cypress/pageobject/Users/UserSearch.ts +++ b/cypress/pageobject/Users/UserSearch.ts @@ -23,7 +23,7 @@ export class UserPage { } checkUsernameText(username: string) { - cy.get(this.usernameText).should("have.text", username); + cy.get(this.usernameText).should("contain.text", username); } checkUsernameBadgeVisibility(shouldBeVisible: boolean) { diff --git a/src/components/Assets/AssetManage.tsx b/src/components/Assets/AssetManage.tsx index 05eab3a4dec..0ee4f107d40 100644 --- a/src/components/Assets/AssetManage.tsx +++ b/src/components/Assets/AssetManage.tsx @@ -432,7 +432,7 @@ const AssetManage = (props: AssetManageProps) => { data-testid="asset-update-button" authorizeFor={NonReadOnlyUsers} > - + {t("update")} {asset?.asset_class && @@ -449,7 +449,7 @@ const AssetManage = (props: AssetManageProps) => { id="configure-asset" data-testid="asset-configure-button" > - + {t("configure")} )} @@ -459,10 +459,9 @@ const AssetManage = (props: AssetManageProps) => { onClick={() => setShowDeleteDialog(true)} variant="danger" data-testid="asset-delete-button" - className="inline-flex" > - - {t("delete")} + + {t("delete")} )} diff --git a/src/components/CameraFeed/ConfigureCamera.tsx b/src/components/CameraFeed/ConfigureCamera.tsx index 03b627d48ce..c0cb19e6a23 100644 --- a/src/components/CameraFeed/ConfigureCamera.tsx +++ b/src/components/CameraFeed/ConfigureCamera.tsx @@ -391,14 +391,22 @@ export default function ConfigureCamera(props: Props) { > setPresetName(value)} errorClassName="hidden" placeholder={t("preset_name_placeholder")} suggestions={presetNameSuggestions} + clearable={true} /> +
+ { + setCreatePreset(undefined); + setPresetName(""); + }} + /> { const { res } = await request(FeedRoutes.createPreset, { diff --git a/src/components/Form/FormFields/TextFormField.tsx b/src/components/Form/FormFields/TextFormField.tsx index a3663358a56..81e1edea9d0 100644 --- a/src/components/Form/FormFields/TextFormField.tsx +++ b/src/components/Form/FormFields/TextFormField.tsx @@ -24,6 +24,7 @@ export type TextFormFieldProps = FormFieldBaseProps & trailingPadding?: string | undefined; leadingPadding?: string | undefined; suggestions?: string[]; + clearable?: boolean | undefined; }; const TextFormField = forwardRef((props: TextFormFieldProps, ref) => { @@ -41,24 +42,36 @@ const TextFormField = forwardRef((props: TextFormFieldProps, ref) => { }; let child = ( - } - id={field.id} - className={classNames( - "cui-input-base peer", - hasLeading && (props.leadingPadding || "pl-10"), - hasTrailing && (props.trailingPadding || "pr-10"), - field.error && "border-danger-500", - props.inputClassName, +
+ } + id={field.id} + className={classNames( + "cui-input-base peer", + hasLeading && (props.leadingPadding || "pl-10"), + hasTrailing && (props.trailingPadding || "pr-10"), + field.error && "border-danger-500", + props.inputClassName, + )} + disabled={field.disabled} + type={props.type === "password" ? getPasswordFieldType() : props.type} + name={field.name} + value={field.value} + required={field.required} + onChange={(e) => field.handleChange(e.target.value)} + /> + {props.clearable && field.value && ( + )} - disabled={field.disabled} - type={props.type === "password" ? getPasswordFieldType() : props.type} - name={field.name} - value={field.value} - required={field.required} - onChange={(e) => field.handleChange(e.target.value)} - /> +
); if (props.type === "password") { diff --git a/src/components/Patient/PatientConsentRecords.tsx b/src/components/Patient/PatientConsentRecords.tsx index 9850cfe0b2c..aa6f45b761c 100644 --- a/src/components/Patient/PatientConsentRecords.tsx +++ b/src/components/Patient/PatientConsentRecords.tsx @@ -219,7 +219,8 @@ export default function PatientConsentRecords(props: { onClick={fileUpload.clearFiles} disabled={fileUpload.uploading} > - + + {t("delete")} ) : ( diff --git a/src/components/Patient/PatientHome.tsx b/src/components/Patient/PatientHome.tsx index d95c6d1df21..fe91bc4e17d 100644 --- a/src/components/Patient/PatientHome.tsx +++ b/src/components/Patient/PatientHome.tsx @@ -591,7 +591,7 @@ export const PatientHome = (props: any) => {

)} -
+
diff --git a/src/components/Patient/SampleDetails.tsx b/src/components/Patient/SampleDetails.tsx index aaf524ef0ae..d74b83dff67 100644 --- a/src/components/Patient/SampleDetails.tsx +++ b/src/components/Patient/SampleDetails.tsx @@ -273,7 +273,7 @@ export const SampleDetails = ({ id }: DetailRoute) => { backUrl="/sample" options={ sampleDetails?.patient && ( -
+