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

Refactor styles for AudioRecorder to prevent overflowing #358

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

Chimise
Copy link

@Chimise Chimise commented May 24, 2023

Status Type Env Vars Change Ticket
Ready Refactor No Closes #320

Problem

Dialectal variation options overflow parent component

Solution

Refactor the inner container styles to use flex-wrap and the children elements to use padding instead of margins. Also, update the audio player to use a new customizable React library.

Before & After Screenshots

BEFORE:
Before

AFTER:
After

QA

  • Manually QA'd the solution

Other changes (e.g. bug fixes, UI tweaks, small refactors)

Changes to the audio player UI, currently display only the audio duration time and the play button.

New dependencies:

  • react-h5-audio-player : A highly customizable audio-player for React apps.

Customize the AudioPlayer to only display a play button and the audio duratio
n time.
@@ -1,7 +1,8 @@
import React, { ReactElement, useEffect, useState } from 'react';
import { has, get } from 'lodash';
import { Record } from 'react-admin';
import ReactAudioPlayer from 'react-audio-player';
Copy link
Collaborator

Choose a reason for hiding this comment

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

do you want to uninstall react-audio-player from the project?

Copy link
Author

Choose a reason for hiding this comment

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

react-audio-player is still used as a dependency in several other components, uninstalling it will break the application. Replacing all use cases of react-audio-player with react-h5-audio-player might also break the UI.

Copy link
Author

Choose a reason for hiding this comment

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

I was thinking the PR has been merged already

@ijemmao
Copy link
Collaborator

ijemmao commented Jun 7, 2023

@Chimise are you still working on this PR?

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.

Dialectal options overflow parent component
2 participants