Commit 24f4c019 authored by Muhammadali's avatar Muhammadali

update-

parent 38a46b5c
{ {
"name": "boxdialer", "name": "boxdialer",
"version": "4.3.6", "version": "4.3.7",
"description": "", "description": "",
"main": "src/boxDialer.js", "main": "src/boxDialer.js",
"scripts": { "scripts": {
......
...@@ -20,10 +20,12 @@ const Block = styled.div` ...@@ -20,10 +20,12 @@ const Block = styled.div`
? { ? {
opacity: '1', opacity: '1',
transform: 'translate(-50%, 0)', transform: 'translate(-50%, 0)',
display: 'block',
} }
: { : {
opacity: '0', opacity: '0',
transform: 'translate(-50%, 0)', transform: 'translate(-50%, 0)',
display: 'none',
}} }}
`; `;
Block.ShowNumbersArea = styled.div` Block.ShowNumbersArea = styled.div`
......
...@@ -41,7 +41,7 @@ const ModalPhoneNumpad = ({ ...@@ -41,7 +41,7 @@ const ModalPhoneNumpad = ({
}, [modalState.bool]); }, [modalState.bool]);
const inputController = ({ value, type, from }) => { const inputController = ({ value, type, from }) => {
// boxDialer.onSoundType({ type: 'pick', bool: true }); boxDialer.onSoundType({ type: 'pick', bool: true });
switch (type) { switch (type) {
case 'add': case 'add':
if ( if (
...@@ -179,7 +179,6 @@ const ModalPhoneNumpad = ({ ...@@ -179,7 +179,6 @@ const ModalPhoneNumpad = ({
// ------------------- // -------------------
var currentTime = new Date(); var currentTime = new Date();
if (dynamicValue === 'connected') { if (dynamicValue === 'connected') {
console.log(call_history.slice(-1), inputValue);
if ( if (
Boolean(inputValue.toString().length) && Boolean(inputValue.toString().length) &&
call_history.slice(-1)[0]?.value != inputValue call_history.slice(-1)[0]?.value != inputValue
......
...@@ -56,6 +56,7 @@ export class BoxDialer { ...@@ -56,6 +56,7 @@ export class BoxDialer {
callSession; callSession;
sipDomain; sipDomain;
player; player;
strmTrack;
constructor() { constructor() {
console.log('registerData: ', this.registerData); console.log('registerData: ', this.registerData);
this.played = false; this.played = false;
...@@ -407,26 +408,14 @@ export class BoxDialer { ...@@ -407,26 +408,14 @@ export class BoxDialer {
'this_callSession_connection: ', 'this_callSession_connection: ',
this.callSession.connection, this.callSession.connection,
); );
this.callSession.connection.addEventListener('addstream', (e) => {
console.log('--== UA Conn Added STREAM: ', e);
let strmTrack = e.stream.getAudioTracks(); this.callSession.connection.onaddstream = (e) => {
if (strmTrack[0]) { this.strmTrack = e.stream.getAudioTracks();
let rmMediaStream = new MediaStream([strmTrack[0]]); if (this.strmTrack[0]) {
this.remoteAudio.srcObject = rmMediaStream; this.remoteAudio.srcObject = new MediaStream([this.strmTrack[0]]);
this.remoteAudio.play();
}
});
let func = (e) => {
let strmTrack = e.stream.getAudioTracks();
if (strmTrack[0]) {
let rmMediaStream = new MediaStream([strmTrack[0]]);
this.remoteAudio.srcObject = rmMediaStream;
this.remoteAudio.play(); this.remoteAudio.play();
} }
}; };
this.callSession.connection.onaddstream = func;
this.setGuiPhoneState({ this.setGuiPhoneState({
funcName: 'modalState', funcName: 'modalState',
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment