@vgroup/dialbox 0.0.86 → 0.0.87

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -2255,35 +2255,6 @@ class DialboxComponent {
2255
2255
  this.isDialpadHidden = false; // Show dialpad on incoming call
2256
2256
  }
2257
2257
  });
2258
- if (this.incomingCallData) {
2259
- this.isCallInProgress = true;
2260
- this.isDialpadHidden = false; // Show dialpad on incoming call
2261
- if (this.isCallInProgress) {
2262
- this.newIncomingCalls.push(this.incomingCallData);
2263
- this.getUserInformation(this.incomingCallData);
2264
- }
2265
- else {
2266
- this.isCallInProgress = true;
2267
- this.isDialpadHidden = false;
2268
- this.callData.phone = this.incomingCallData.parameters['From'];
2269
- this.getUserInformation(this.incomingCallData);
2270
- this.callData.name = this.incomingCallData.customParameters.get('name');
2271
- this.callData.img = this.incomingCallData.customParameters.get('image') || 'assets/images/user.jpg';
2272
- this.callData.isIncomingCall = true;
2273
- }
2274
- this.incomingCallData.on('cancel', () => {
2275
- this.incomingCallsList = this.incomingCallsList.filter((item) => item.parameters['CallSid'] !== this.incomingCallData.parameters['CallSid']);
2276
- if (this.incomingCallsList.length == 0) {
2277
- this.isCallInProgress = false;
2278
- }
2279
- });
2280
- this.incomingCallData.on('disconnect', () => {
2281
- this.incomingCallsList = this.incomingCallsList.filter((item) => item.parameters['CallSid'] !== this.incomingCallData.parameters['CallSid']);
2282
- if (this.incomingCallsList.length == 0) {
2283
- this.isCallInProgress = false;
2284
- }
2285
- });
2286
- }
2287
2258
  this.subscriptions.add(callSub);
2288
2259
  }
2289
2260
  // ngOnChange() {
@@ -2518,6 +2489,35 @@ class DialboxComponent {
2518
2489
  this.dialInputElement.nativeElement.focus();
2519
2490
  }, 0);
2520
2491
  }
2492
+ if (this.incomingCallData) {
2493
+ // this.isCallInProgress = true;
2494
+ // this.isDialpadHidden = false; // Show dialpad on incoming call
2495
+ if (this.isCallInProgress) {
2496
+ this.newIncomingCalls.push(this.incomingCallData);
2497
+ this.getUserInformation(this.incomingCallData);
2498
+ }
2499
+ else {
2500
+ this.isCallInProgress = true;
2501
+ this.isDialpadHidden = false;
2502
+ this.callData.phone = this.incomingCallData.parameters['From'];
2503
+ this.getUserInformation(this.incomingCallData);
2504
+ this.callData.name = this.incomingCallData.customParameters.get('name');
2505
+ this.callData.img = this.incomingCallData.customParameters.get('image') || 'assets/images/user.jpg';
2506
+ this.callData.isIncomingCall = true;
2507
+ }
2508
+ this.incomingCallData.on('cancel', () => {
2509
+ this.incomingCallsList = this.incomingCallsList.filter((item) => item.parameters['CallSid'] !== this.incomingCallData.parameters['CallSid']);
2510
+ if (this.incomingCallsList.length == 0) {
2511
+ this.isCallInProgress = false;
2512
+ }
2513
+ });
2514
+ this.incomingCallData.on('disconnect', () => {
2515
+ this.incomingCallsList = this.incomingCallsList.filter((item) => item.parameters['CallSid'] !== this.incomingCallData.parameters['CallSid']);
2516
+ if (this.incomingCallsList.length == 0) {
2517
+ this.isCallInProgress = false;
2518
+ }
2519
+ });
2520
+ }
2521
2521
  }
2522
2522
  registerDragElement() {
2523
2523
  try {