Skip to content

Commit

Permalink
Merge pull request #203 from ajinkyapandetekdi/all-rig-v1-0.4
Browse files Browse the repository at this point in the history
Issue Id #213337 feat: Implement Audio Preprocessing Toggle Feature in Test-Rig
  • Loading branch information
gouravmore authored Feb 6, 2024
2 parents 0bf0148 + c310f92 commit 79f0456
Show file tree
Hide file tree
Showing 6 changed files with 3 additions and 5 deletions.
1 change: 1 addition & 0 deletions .github/workflows/aws.yml
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@ jobs:
REACT_APP_AWS_SECRET_ACCESS_KEY=${{ secrets.REACT_APP_AWS_SECRET_ACCESS_KEY }} \
REACT_APP_AWS_S3_BUCKET_CONTENT_URL=https://all-dev-content-service.s3.ap-south-1.amazonaws.com \
REACT_APP_MIN_DECIBELS=-75 \
REACT_APP_IS_AUDIOPREPROCESSING=true \
npm run build
- name: Deploy to S3 Bucket
run: |
Expand Down
3 changes: 2 additions & 1 deletion src/components/VoiceCompair/VoiceCompair.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ import axios from 'axios';
import { useToast } from '@chakra-ui/react';

const VoiceCompair = props => {
const [isAudioPreprocessing,setIsAudioPreprocessing] = useState(process.env.REACT_APP_IS_AUDIOPREPROCESSING === 'true')
const [lang_code, set_lang_code] = useState(
localStorage.getItem('apphomelang')
? localStorage.getItem('apphomelang')
Expand Down Expand Up @@ -374,7 +375,7 @@ const VoiceCompair = props => {
/>
) : ( */}
<AudioRecorderCompairUI
isAudioPreprocessing={props.isAudioPreprocessing}
isAudioPreprocessing={isAudioPreprocessing}
toast={toast}
setRecordedAudio={setRecordedAudio}
flag={props.flag}
Expand Down
1 change: 0 additions & 1 deletion src/pages/Story/Discover.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -474,7 +474,6 @@ const handleSubmit = () => {
<div className='voice-recorder'>
<VStack>
<VoiceCompair
isAudioPreprocessing = {true}
setVoiceText={setVoiceText}
setRecordedAudio={setRecordedAudio}
_audio={{ isAudioPlay: e => setIsAudioPlay(e) }}
Expand Down
1 change: 0 additions & 1 deletion src/pages/Story/Showcase.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -578,7 +578,6 @@ const Showcase = ({forceRerender, setForceRerender}) => {
<div className='voice-recorder'>
<VStack>
<VoiceCompair
isAudioPreprocessing = {true}
setVoiceText={setVoiceText}
setRecordedAudio={setRecordedAudio}
_audio={{ isAudioPlay: e => setIsAudioPlay(e) }}
Expand Down
1 change: 0 additions & 1 deletion src/pages/Story/Story.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -354,7 +354,6 @@ const Story = () => {
<div className='voice-recorder'>
<VStack>
<VoiceCompair
isAudioPreprocessing = {true}
setVoiceText={setVoiceText}
setRecordedAudio={setRecordedAudio}
_audio={{ isAudioPlay: e => setIsAudioPlay(e) }}
Expand Down
1 change: 0 additions & 1 deletion src/pages/Test-Rig-Two/Story/Story.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -728,7 +728,6 @@ const Story = ({ forceRerender, setForceRerender }) => {
style={{ marginTop: '-13px', marginLeft: '0px' }}
>
<VoiceCompair
isAudioPreprocessing = {false}
setVoiceText={setVoiceText}
setRecordedAudio={setRecordedAudio}
_audio={{ isAudioPlay: e => setIsAudioPlay(e) }}
Expand Down

0 comments on commit 79f0456

Please sign in to comment.