Quantcast
Channel: Ionic Framework - Ionic Forum
Viewing all 49300 articles
Browse latest View live

Nativescript like code sharing in Ionic (mono repo)?

$
0
0

@aki-ks wrote:

Is it possible to share the “code” for a regular webpage and an ionic app in a Nativescript like fashion?
When developing Nativescript Angular applications, multiple html and css files are provided per component, one for each platform.

So could e.g. a component in an Ionic app be structured like this:

  • hello-world.component.ts
  • hello-world.component.html (the web html file)
  • hello-world.component.ionic.html (the ionic html file)
  • hello-world.component.scss (the web stylesheet)
  • hello-world.component.ionic.scss (the ionic stylesheet)

Posts: 1

Participants: 1

Read full topic


Ion-searchbar: pass filtered list results to another page

$
0
0

@iondo wrote:

I´m trying to pass filtered list results to another page. I´m using the ion-searchbar in my filter-page.html:

<ion-searchbar [(ngModel)]="searchTerm" (ionChange)="setFilteredItems(searchTerm)"></ion-searchbar>

And here my typescript:

import { Component, OnInit } from '@angular/core';
import { searchService} from '../../services/search.service';
import { searchInter} from '../../interface/search';

@Component({
  selector: 'app-filter',
  templateUrl: './filter.page.html',
  styleUrls: ['./filter.page.scss'],
})
export class FilterPage implements OnInit {
  searchTitle$: SearchInter[] = [];
  public items: any;

  constructor(
      private searchService: SearchService) {
  }

  ngOnInit() {
  }
  
  // Searchbar: set filtered Vorhabentitles
  setFilteredVorhaben(searchTerm) {
    this.searchService.getTitlesForSearch(searchTerm).subscribe(vorhaben => {
      this.searchTitle$ = vorhaben;
    });
  }
}

The request from the service works fine, I get my filtered items.
But how can I pass these filtered list to another page? Maybe I only want to to integrate my searchbar in a modal window and want press the results button to see these filtered results in the dashboard page.

Any idea?

Posts: 1

Participants: 1

Read full topic

Ionic 5 - How can i disable "back swipe" in IOS?

$
0
0

@nscuri wrote:

Hi,

I need to disable ios swipe on specific pages, but I can’t find a way to do it.

I also tried some solutions that I found in other threads, but none is compatible with Ionic 5. For example, in ionic 2 you can use:

<ion-view can-swipe-back="false">

I need the equivalent from ionic 5.

I could only disable swipe on ALL pages by adding the following to the app.module:

IonicModule.forRoot({
            swipeBackEnabled: false // A better spot to set swipe enabled also…
        }),

But i need disable only one…

stack:
Ionic: v5.16.0
Angular: v8.2.8

Thanks!

Posts: 1

Participants: 1

Read full topic

Issue with ion-header

$
0
0

@andyhb wrote:

I am using the latest ionic 5 cli and I am using the popover controller to display a popup, however the ion-header is not fixed within the popup it simply scrolls with the other content, is this by design?

<ion-header *ngIf="hasSearchbar">
    <ion-toolbar>
        <ion-buttons slot="start">
            <ion-icon name="search"></ion-icon>
        </ion-buttons>
        <ion-input></ion-input>
    </ion-toolbar>
</ion-header>
<ion-content fullscreen="true">
    <ion-list>
        <ion-item
            *ngFor="let option of configuration.options"
            button="true"
            (click)="selectOption(option)"
        >
            <ion-label>{{ option[nameForText] }}</ion-label>
            <ion-icon
                *ngIf="isSelected(option[nameForValue])"
                slot="end"
                name="checkmark"
            ></ion-icon>
        </ion-item>
    </ion-list>
</ion-content>

Posts: 1

Participants: 1

Read full topic

How can I remove extra height at the bottom of text in android: - IONIC4*

$
0
0

@rajashekarra wrote:

Hi All,

I have encountered with a weird issue with ionic4 framework. Ionic4 is adding extra height at the bottom of the text in Android, where as on iOS the above and below height is same.

Below is sample code
< ion-label id=“newactivity” class=“recent-header activity-label” >New ACTIVITY</ ion-label >

Not only on ion-label but where ever I have text in the app, the extra space/height is being added at the bottom on Android app.

[the above image is when am debugging in chrome]

If you observe very closely the text is not center aligned ON ANDROID, ( which works fine in iOS*)
No padding or margin is applied. only text-align center is applied,

To make the text to appear CENTER on android, I have to add 2px extra padding on top of every text element.

I hate to add padding on each and every element like this,

Really appreciate if you can suggest me to make it work.

Note: There is nothing to do with CSS (like flex,justify, line height etc), the extra height is added at bottom on ANDROID. on the text itself.

To understand the issue, inspect any ionic app on android and hover on text (don’t apply any css property or padding and closely check above and below height of the text)

Related observations and solutions are much appreciated.

Thank you

Posts: 1

Participants: 1

Read full topic

Ionic 4 detect when html 5 audio player starts playing

$
0
0

@alex001 wrote:

Hi,
I have a number of audio files loaded on page similar to how it is written below:

<ion-item *ngFor="let programme of radioProgrammes" class="radio-file">
              <audio controls preload>
                <source [src]="programme.radio_file" type="audio/mpeg">
                Your device does not support the audio element.
              </audio>
</ion-item>

The issue is I want to stop the user from playing more than 1 audio file at a time.

I have already written a function pause all other audio files if they are playing but but I cant figure out how to detect when the file starts playing.

I originally tried adding (click)=“pauseOtherPlayers()” to call the function eg:

 <audio (click)="pauseOtherPlayers()" controls preload>
                <source [src]="programme.radio_file" type="audio/mpeg">
                Your device does not support the audio element.
</audio>

but that didn’t work.

Thanks in advanced to anyone who can help me with this issue.

Posts: 1

Participants: 1

Read full topic

Updating list upon ionic storage set() completion

$
0
0

@crocrobot wrote:

Sorry in advance for the the lengthy post.

I am still pretty new to the PWA world and am having trouble getting values added to Storage to show up upon return to my customer list

My Service:

import { Injectable } from '@angular/core';
import { Storage } from '@ionic/storage';
import { Customer } from './models/customer';
import { StorageConstants } from './storageConstants';
import { Observable } from 'rxjs/Observable';
import { from } from 'rxjs';
import { map, tap } from 'rxjs/operators';

@Injectable({
  providedIn: 'root'
})
export class CustomersService {

  constructor(private storage: Storage) { }

  getCustomers() : Observable<Customer[]>{
    return from(this.storage.get(StorageConstants.customers)).pipe(
      map((customers) => {
        return customers ? JSON.parse(customers).map(
          (customer: Customer) => new Customer(customer)) : []
      })
    )
  }

  addCustomer(customer: Customer) {
    let customers_update: Customer[];
    return this.getCustomers().pipe(
      tap(
        (customers : Customer[]) => {
          customers_update = customers;
          customers_update.push(customer);
          this.storage.set(
            StorageConstants.customers, JSON.stringify(customers_update));
        }
      )
    );
  }
}

My Form component

import { Component, ViewChild, OnInit } from '@angular/core';
import { Validators, FormBuilder, FormGroup } from '@angular/forms';
import { CustomersService } from '../customers.service';
import { Customer } from '../models/customer';
import { Router } from '@angular/router';

@Component({
  selector: 'app-customer-form',
  templateUrl: './customer-form.page.html',
  styleUrls: ['./customer-form.page.scss'],
})
export class CustomerFormPage implements OnInit{
  @ViewChild('customerForm', {static: false}) formValues;

  private  addCustomer: FormGroup;
  constructor(
    private formBuilder: FormBuilder,
    private customersService: CustomersService,
    private router: Router
  ) {
    
    this.addCustomer = this.formBuilder.group(
      {
        name: ['', Validators.required],
        phone: ['', Validators.required],
        email: ['']
      }
    );
   }

   ngOnInit() {}

  onSubmit() {
      const newCustomer: Customer = new Customer(
        {
          name: this.addCustomer.value.name,
          phone: this.addCustomer.value.phone,
          email: this.addCustomer.value.email
        }
      );

      this.customersService.addCustomer(newCustomer).subscribe(
        {
          complete: () => this.router.navigate(['tabs', 'customers'])
        }
      );
  }

}

My list component

import { Component, OnInit } from '@angular/core';
import { CustomersService } from '../customers.service';
import { Customer } from '../models/customer';
import { NavController } from '@ionic/angular';
import { Observable } from 'rxjs';

@Component({
  selector: 'customers',
  templateUrl: 'customers.page.html',
  styleUrls: ['customers.page.scss']
})
export class CustomersPage implements OnInit{

  private customers: Observable<Customer[]>;

  constructor(private customersService: CustomersService) {}

  ngOnInit(): any {
    this.customers = this.customersService.getCustomers();
  }
}

List html

<ion-content>
  <div *ngFor="let customer of customers | async">
    <h2>{{customer.name}} {{customer.phone}}</h2>
  </div>
</ion-content>

<ion-fab vertical="bottom" horizontal="end" slot="fixed">
  <ion-fab-button [routerLink]="['add-customer']">
    <ion-icon name="add"></ion-icon>
  </ion-fab-button>
</ion-fab>

Adding a customer via the addCustomer method in the service adds to Storage, but the list in the component is only updated upon refresh. I looked around and tried a lot of solutions, but I think I am missing a fundamental understanding about how these pieces are working together.

Any help is greatly appreciated.

Posts: 2

Participants: 2

Read full topic

Ion-Virtual-Scroll render problem


Ion-select-option unable to give any event

$
0
0

@soham07 wrote:

I want to implement select all functionality for . this is what i did

<ion-select multiple=“true” [(ngModel)]=“day” name=“day” (select)=“selectAll(myselect)” required >

  <ion-select-option  value="selectall" (onSelect)="SelectAll()"> select all</ion-select-option>

   

  <ion-select-option value="Monday">Monday</ion-select-option>

   <ion-select-option value="Tuesday">Tuesday</ion-select-option>

   <ion-select-option value="Wednesday">Wednesday</ion-select-option>

   <ion-select-option value="Thursday">Thursday </ion-select-option>

   <ion-select-option value="Friday">Friday </ion-select-option>

   <ion-select-option value="Saturday">Saturday</ion-select-option>

   <ion-select-option value="Sunday">Sunday </ion-select-option>

 </ion-select>

I am not able to give any event on . I checked the response at console and nothing was reflected there.
Instead of (onSelect): - (onChange), (change), (select) was tried.

Posts: 1

Participants: 1

Read full topic

I get error when i use social-sharing on ionic3

$
0
0

@sanjay70 wrote:

I got a run time error when click the facebook btn for share …

this.socialSharing.shareViaFacebook(“text”, null, null).then(() => {

  console.log("shareViaFacebook: Success");

}).catch(() => {

  console.error("shareViaFacebook: failed");

}); 

And also other social share.

ionic-error-2

Posts: 1

Participants: 1

Read full topic

View Documents inside App, works on WEB but not on ANDROID and iOS

$
0
0

@mhoxha wrote:

Hello guys, I hope you all doing well.

I have an APP that i need to load document files from storage using API. I have managed to open IMAGES, WORD Documents, PDFs on WEB, but I am Struggling on iOS and Android.

On iOS files are opened but only the first page, can’t scroll on different pages, while on Android it shows blank page, this goes with word documents and pdf files, images are opening well, while on web when running ionic serve it is all working well.

For this I have used iFrame, I am opening files via DomSanitizer using URLSearchParams bypassSecurityTrustResourceUrl, I also need to do pinch and zoom on iFrame but that cant seem to be possible.

If you have any other that you suggest that would also be worth a try please let me know.

This is iFrame.html:

<div class="iframe-fix">
     <iframe
         [src]="iFrameFileSelected"
         frameborder="0"
         webkitallowfullscreen
         mozallowfullscreen
         allowfullscreen
         width="100%"
         height="550px"
         zooming="true"
         scrolling="yes"
       ></iframe>
     </div>

and this is .ts file of the iframe:

iFrameFileSelected: SafeResourceUrl | SafeHtml | SafeStyle | SafeScript | SafeUrl  = null;

  params: any = {
    id: null,
    uuid: null,
    token: null
  };

constructor(protected sanitizer: DomSanitizer) {
  this.iFrameFileSelected = this.sanitizer.bypassSecurityTrustResourceUrl(this.getMedia + paramsii);
}

Thank you very much.

Posts: 1

Participants: 1

Read full topic

Ionic 4 - keyboard covers input field

$
0
0

@LookAndEat wrote:

Ionic 4: The Keyboard overlaps input on Ios, Android works fine.

When the user clicks on the input, it opens the keyboard, but it hides the content without scrolling.
I would like that the screen slide up and the keyboard doesn’t cover the input.

I’ve seen the same issue in many topics of ionic forum, but nobody knows how can resolve it.

Posts: 1

Participants: 1

Read full topic

Ngx-translate does not change the language in the ion-menu of the AppComponent

$
0
0

@codiqa100075846 wrote:

Hello,
I use the ngx-translate library in my application, I noticed that the links in AppComponent do not change.

All other information changes except the url of the links, the titles are well translated and are in the correct language, but the value of the “href” remains unchanged, knowing that the url in the navigation bar contains the correct language .

Is there a way to force AppComponent to refresh its information when the language change.

Thanks for your help.

<ion-menu-toggle auto-hide="false" *ngFor="let page of appPages">
	<ion-item [routerLinkActive]="'active'"
		  [routerLink]="page.url | localize" <!--the value does not change-->
		  [routerDirection]="'root'">
		<ion-icon slot="start" [name]="page.icon"></ion-icon>
		<ion-label>
			{{page.title | translate}}  <!--returns the right value-->
			{{page.url | localize}}     <!--returns the right value-->
		</ion-label>
	</ion-item>
</ion-menu-toggle>

Posts: 1

Participants: 1

Read full topic

Why cannot call scss from html in ionic4?

$
0
0

@Hyonta wrote:

If I wrote the style directly in the html it can be applied, but I can’t call scss using class in html.
Why I can’t call scss from html?

login.page.ts

..
@Component({
  selector: 'page-login',
  templateUrl: 'login.page.html',
  styleUrls: ['login.page.scss'],
  providers: [CustomNativeStorage]
})
..

login.page.html

<ion-content>
..
  <div class="welcome_text">
    <h4>WELCOME_TEXT</h4>
  </div>
..
</ion-content>

login.page.scss

page-login {
  .welcome_text{
    margin-top: 50px;
    color: white;
    text-align: center;
  }
..
}

Posts: 1

Participants: 1

Read full topic

iOS App stuck at white Screen after SplashScreen

$
0
0

@Sunny595 wrote:

Hi Guys,
I am trying to get my iOS App to run. Android works totally fine.
The build with XCode succeeds and the App is fully installed.
The App ist starting, the Splashscreen shows and after that, the Screen stays white.
No matter how long I wait. Same thing with the emulator and a real device.

I have the cordova plugin firebase-x installed, which might cause the problem.
What the app does however, is registering the token to the firebase database. so this seems to be working…

I am new to developing with Apple, so the console output of XCode is very cryptic.

I even tried to look at possible outputs with safari technology preview but it couldn’t connect to the iPhone., but the device does at least appear in the drawer…

Here’s the console output of XCode, maybe that helps…

2020-02-06 11:10:08.483594+0100 Loesdau[5760:61694] DiskCookieStorage changing policy from 2 to 0, cookie file: file:///Users/.../Library/Developer/CoreSimulator/Devices/C5B461C0-2E7C-4718-91D2-C5954DF339E8/data/Containers/Data/Application/B4A9F300-E0F2-4504-B7DA-68B95E0B2589/Library/Cookies/com.loesdau.appaloosa.binarycookies
2020-02-06 11:10:08.491060+0100 Loesdau[5760:61694] You've implemented -[<UIApplicationDelegate> application:didReceiveRemoteNotification:fetchCompletionHandler:], but you still need to add "remote-notification" to the list of your supported UIBackgroundModes in your Info.plist.
2020-02-06 11:10:08.492076+0100 Loesdau[5760:61694] Apache Cordova native platform version 5.1.1 is starting.
2020-02-06 11:10:08.492225+0100 Loesdau[5760:61694] Multi-tasking -> Device: YES, App: YES
2020-02-06 11:10:08.505543+0100 Loesdau[5760:61795]  - <AppMeasurement>[I-ACS036002] Analytics screen reporting is enabled. Call +[FIRAnalytics setScreenName:setScreenClass:] to set the screen name or override the default screen class name. To disable screen reporting, set the flag FirebaseScreenReportingEnabled to NO (boolean) in the Info.plist
2020-02-06 11:10:08.651868+0100 mac[5760:61797] 6.3.0 - [Firebase/Analytics][I-ACS023007] Analytics v.60002000 started
2020-02-06 11:10:08.654512+0100 mac the following application argument: -FIRAnalyticsDebugEnabled (see http://goo.gl/RfcP7r)
2020-02-06 11:10:08.655171+0100 mac[5760:61797] 6.3.0 - [Firebase/Messaging][I-FCM001000] FIRMessaging Remote Notifications proxy enabled, will swizzle remote notification receiver handlers. If you'd prefer to manually integrate Firebase Messaging, add "FirebaseAppDelegateProxyEnabled" to your Info.plist, and set it to NO. Follow the instructions at:
https://firebase.google.com/docs/cloud-messaging/ios/client#method_swizzling_in_firebase_messaging
to ensure proper integration.
2020-02-06 11:10:08.676359+0100 mac[5760:61694] Using UIWebView
2020-02-06 11:10:08.677829+0100 mac[5760:61694] [CDVTimer][console] 0.054002ms
2020-02-06 11:10:08.677992+0100 mac[5760:61694] [CDVTimer][handleopenurl] 0.047088ms
2020-02-06 11:10:08.679204+0100 mac[5760:61694] [CDVTimer][intentandnavigationfilter] 1.122952ms
2020-02-06 11:10:08.679357+0100 mac[5760:61694] [CDVTimer][gesturehandler] 0.046015ms
2020-02-06 11:10:08.680071+0100 mac[5760:61694] [CDVTimer][file] 0.623941ms
2020-02-06 11:10:08.680171+0100 mac[5760:61694] [CDVTimer][TotalPluginStartup] 2.418041ms
2020-02-06 11:10:08.690669+0100 mac[5760:61694] DidFinishLaunchingWithOptions
2020-02-06 11:10:08.695935+0100 mac[5760:61694] Device FCM Token: cw51FUQjcq4:APA91bEfMtTVWcltb1wfoRLAamRVgFHYLOrGVymGyf3lRz6rHO1uyOARxKiOx7HEZ7G-GGEKlp7U8wUZovOpB1E-JLWsNlyUqJ70rZWjkRnZIwC2XQj7b5PwpQScktQu7U_QnUbbssVL
2020-02-06 11:10:08.696051+0100 mac[5760:61694] setInitialFCMToken token: cw51FUQjcq4:APA91bEfMtTVWcltb1wfoRLAamRVgFHYLOrGVymGyf3lRz6rHO1uyOARxKiOx7HEZ7G-GGEKlp7U8wUZovOpB1E-JLWsNlyUqJ70rZWjkRnZIwC2XQj7b5PwpQScktQu7U_QnUbbssVL
2020-02-06 11:10:08.698991+0100 mac[5760:61694] app become active
=================================================================
Main Thread Checker: UI API called on a background thread: -[UIApplication registerForRemoteNotifications]
PID: 5760, TID: 61798, Thread name: (none), Queue name: com.apple.usernotifications.UNUserNotificationServiceConnection.call-out, QoS: 0
Backtrace:
4   mac                             0x000000010ed22a34 __73-[AppDelegate(MCPlugin) application:customDidFinishLaunchingWithOptions:]_block_invoke + 116
5   libdispatch.dylib                   0x0000000111738dd4 _dispatch_call_block_and_release + 12
6   libdispatch.dylib                   0x0000000111739d48 _dispatch_client_callout + 8
7   libdispatch.dylib                   0x00000001117405ef _dispatch_lane_serial_drain + 788
8   libdispatch.dylib                   0x00000001117411b5 _dispatch_lane_invoke + 476
9   libdispatch.dylib                   0x000000011174ca4e _dispatch_workloop_worker_thread + 719
10  libsystem_pthread.dylib             0x00007fff524636fc _pthread_wqthread + 290
11  libsystem_pthread.dylib             0x00007fff52462827 start_wqthread + 15
2020-02-06 11:10:08.702474+0100 mac[5760:61798] [reports] Main Thread Checker: UI API called on a background thread: -[UIApplication registerForRemoteNotifications]
PID: 5760, TID: 61798, Thread name: (none), Queue name: com.apple.usernotifications.UNUserNotificationServiceConnection.call-out, QoS: 0
Backtrace:
4   mac                             0x000000010ed22a34 __73-[AppDelegate(MCPlugin) application:customDidFinishLaunchingWithOptions:]_block_invoke + 116
5   libdispatch.dylib                   0x0000000111738dd4 _dispatch_call_block_and_release + 12
6   libdispatch.dylib                   0x0000000111739d48 _dispatch_client_callout + 8
7   libdispatch.dylib                   0x00000001117405ef _dispatch_lane_serial_drain + 788
8   libdispatch.dylib                   0x00000001117411b5 _dispatch_lane_invoke + 476
9   libdispatch.dylib                   0x000000011174ca4e _dispatch_workloop_worker_thread + 719
10  libsystem_pthread.dylib             0x00007fff524636fc _pthread_wqthread + 290
11  libsystem_pthread.dylib             0x00007fff52462827 start_wqthread + 15
2020-02-06 11:10:08.807263+0100 mac[5760:61795] 6.3.0 - [Firebase/Messaging][I-FCM012002] Error in application:didFailToRegisterForRemoteNotificationsWithError: remote notifications are not supported in the simulator
2020-02-06 11:10:08.815503+0100 mac[5760:61694] Resetting plugins due to page load.
2020-02-06 11:10:08.825136+0100 mac[5760:61694] Failed to load webpage with error: The operation couldn’t be completed. (NSURLErrorDomain error -999.)
2020-02-06 11:10:08.827663+0100 mac[5760:61694] Resetting plugins due to page load.
2020-02-06 11:10:08.895176+0100 mac[5760:61795] NSURLConnection finished with error - code -1100
2020-02-06 11:10:08.896712+0100 mac[5760:61796] NSURLConnection finished with error - code -1100
2020-02-06 11:10:08.897809+0100 mac[5760:61796] NSURLConnection finished with error - code -1100
2020-02-06 11:10:08.898487+0100 mac[5760:61795] NSURLConnection finished with error - code -1100
2020-02-06 11:10:08.899125+0100 mac[5760:61796] NSURLConnection finished with error - code -1100
2020-02-06 11:10:08.899758+0100 mac[5760:61796] NSURLConnection finished with error - code -1100
2020-02-06 11:10:08.906616+0100 mac[5760:61694] Finished load of: file:///Users/.../Library/Developer/CoreSimulator/Devices/C5B461C0-2E7C-4718-91D2-C5954DF339E8/data/Containers/Bundle/Application/6C12842F-DDCE-4D08-BA3F-2A6F3CBA3F70/Loesdau.app/www/index.html
2020-02-06 11:10:32.620097+0100 mac[5760:61908] Task <85B1C25E-ED54-4164-94C4-6279E04434F7>.<1> HTTP load failed, 454/0 bytes (error code: -1017 [4:-1])
2020-02-06 11:10:32.620679+0100 mac[5760:61694] Task <85B1C25E-ED54-4164-94C4-6279E04434F7>.<1> finished with error [-1017] Error Domain=NSURLErrorDomain Code=-1017 "cannot parse response" UserInfo={_kCFStreamErrorCodeKey=-1, NSUnderlyingError=0x600003797390 {Error Domain=kCFErrorDomainCFNetwork Code=-1017 "(null)" UserInfo={NSErrorPeerAddressKey=<CFData 0x600001a2e760 [0x7fff80617cb0]>{length = 16, capacity = 16, bytes = 0x100201bbacd910aa0000000000000000}, _kCFStreamErrorCodeKey=-1, _kCFStreamErrorDomainKey=4}}, _NSURLErrorFailingURLSessionTaskErrorKey=LocalUploadTask <85B1C25E-ED54-4164-94C4-6279E04434F7>.<1>, _NSURLErrorRelatedURLSessionTaskErrorKey=(
    "LocalUploadTask <85B1C25E-ED54-4164-94C4-6279E04434F7>.<1>"
), NSLocalizedDescription=cannot parse response, NSErrorFailingURLStringKey=https://play.googleapis.com/log, NSErrorFailingURLKey=https://play.googleapis.com/log, _kCFStreamErrorDomainKey=4}
2020-02-06 11:10:32.620859+0100 mac[5760:61694] <Google/Utilities/Network/ERROR> Encounter network error. Code, error: -1017, Error Domain=NSURLErrorDomain Code=-1017 "cannot parse response" UserInfo={_kCFStreamErrorCodeKey=-1, NSUnderlyingError=0x600003797390 {Error Domain=kCFErrorDomainCFNetwork Code=-1017 "(null)" UserInfo={NSErrorPeerAddressKey=<CFData 0x600001a2e760 [0x7fff80617cb0]>{length = 16, capacity = 16, bytes = 0x100201bbacd910aa0000000000000000}, _kCFStreamErrorCodeKey=-1, _kCFStreamErrorDomainKey=4}}, _NSURLErrorFailingURLSessionTaskErrorKey=LocalUploadTask <85B1C25E-ED54-4164-94C4-6279E04434F7>.<1>, _NSURLErrorRelatedURLSessionTaskErrorKey=(
    "LocalUploadTask <85B1C25E-ED54-4164-94C4-6279E04434F7>.<1>"
), NSLocalizedDescription=cannot parse response, NSErrorFailingURLStringKey=https://play.googleapis.com/log, NSErrorFailingURLKey=https://play.googleapis.com/log, _kCFStreamErrorDomainKey=4}
2020-02-06 11:10:32.623249+0100 mac[5760:61910] 6.3.0 - [GULNetwork][I-NET901017] <Google/Utilities/Network/ERROR> Encounter network error. Code, error: -1017, Error Domain=NSURLErrorDomain Code=-1017 "cannot parse response" UserInfo={_kCFStreamErrorCodeKey=-1, NSUnderlyingError=0x600003797390 {Error Domain=kCFErrorDomainCFNetwork Code=-1017 "(null)" UserInfo={NSErrorPeerAddressKey=<CFData 0x600001a2e760 [0x7fff80617cb0]>{length = 16, capacity = 16, bytes = 0x100201bbacd910aa0000000000000000}, _kCFStreamErrorCodeKey=-1, _kCFStreamErrorDomainKey=4}}, _NSURLErrorFailingURLSessionTaskErrorKey=LocalUploadTask <85B1C25E-ED54-4164-94C4-6279E04434F7>.<1>, _NSURLErrorRelatedURLSessionTaskErrorKey=(
    "LocalUploadTask <85B1C25E-ED54-4164-94C4-6279E04434F7>.<1>"
), NSLocalizedDescription=cannot parse response, NSErrorFailingURLStringKey=https://play.googleapis.com/log, NSErrorFailingURLKey=https://play.googleapis.com/log, _kCFStreamErrorDomainKey=4}
2020-02-06 11:10:32.623861+0100 mac[5760:61910] 6.3.0 - [Firebase/Core][I-COR000020] Error posting to Clearcut: Error Domain=NSURLErrorDomain Code=-1017 "cannot parse response" UserInfo={_kCFStreamErrorCodeKey=-1, NSUnderlyingError=0x600003797390 {Error Domain=kCFErrorDomainCFNetwork Code=-1017 "(null)" UserInfo={NSErrorPeerAddressKey=<CFData 0x600001a2e760 [0x7fff80617cb0]>{length = 16, capacity = 16, bytes = 0x100201bbacd910aa0000000000000000}, _kCFStreamErrorCodeKey=-1, _kCFStreamErrorDomainKey=4}}, _NSURLErrorFailingURLSessionTaskErrorKey=LocalUploadTask <85B1C25E-ED54-4164-94C4-6279E04434F7>.<1>, _NSURLErrorRelatedURLSessionTaskErrorKey=(
    "LocalUploadTask <85B1C25E-ED54-4164-94C4-6279E04434F7>.<1>"
), NSLocalizedDescription=cannot parse response, NSErrorFailingURLStringKey=https://play.googleapis.com/log, NSErrorFailingURLKey=https://play.googleapis.com/log, _kCFStreamErrorDomainKey=4}, with Status Code: 0

Ionic info

   Ionic CLI                     : 5.4.15
   Ionic Framework               : @ionic/angular 4.11.7
   @angular-devkit/build-angular : 0.803.23
   @angular-devkit/schematics    : 8.1.3
   @angular/cli                  : 8.1.3
   @ionic/angular-toolkit        : 2.0.0

XCode Version: 11.3.1 (11C504)

MacOS Version: macOS Catalina Version 10.15.2

iOS Version: 12.4.5

i really hope, you can help me :heart:

Posts: 1

Participants: 1

Read full topic


storage.forEach not working

$
0
0

@jdpsahjaideep wrote:

Hi, Can anyone please help with this issue, I am using ionic storage Ionic-Storage and I am trying to get all the data from that storage using storage.forEach() but the problem is while looping my app is getting closed when the huge data is present in that storage. Around 2000 records. If there is any other option to get data from storage instead of forEach then please suggest.

Thanks

Posts: 1

Participants: 1

Read full topic

IONIC 4 ion-menu Menu ERROR when opening closing

$
0
0

@mhoxha wrote:

Hello guys,

I hope you are all doing well.

I am facing an issue with MENU Controller on IONIC 4 App.

When the user clicks on the MENU and opens it and closes it several times i get errors:

helpers-46f4a262.js:44 ASSERT: _before() should be called while animating

Uncaught (in promise) Error: ASSERT: _before() should be called while animating
    at assert (helpers-46f4a262.js:46)
    at Menu.afterAnimation (ion-menu_4-md.entry.js:340)
    at Menu._setOpen (ion-menu_4-md.entry.js:200)
beforeAnimation(shouldOpen) {
        assert(!this.isAnimating, '_before() should not be called while animating');
        // this places the menu into the correct location before it animates in
        // this css class doesn't actually kick off any animations
        this.el.classList.add(SHOW_MENU);
        if (this.backdropEl) {
            this.backdropEl.classList.add(SHOW_BACKDROP);
        }
        this.blocker.block();
        this.isAnimating = true;
        if (shouldOpen) {
            this.ionWillOpen.emit();
        }
        else {
            this.ionWillClose.emit();
        }
    }
    afterAnimation(isOpen) {
        assert(this.isAnimating, '_before() should be called while animating');
        // keep opening/closing the menu disabled for a touch more yet
        // only add listeners/css if it's enabled and isOpen
        // and only remove listeners/css if it's not open
        // emit opened/closed events
        this._isOpen = isOpen;
        this.isAnimating = false;
        if (!this._isOpen) {
            this.blocker.unblock();
        }
        if (isOpen) {
            // add css class
            if (this.contentEl) {
                this.contentEl.classList.add(MENU_CONTENT_OPEN);
            }
            // emit open event
            this.ionDidOpen.emit();
        }
        else {
            // remove css classes
            this.el.classList.remove(SHOW_MENU);
            if (this.contentEl) {
                this.contentEl.classList.remove(MENU_CONTENT_OPEN);
            }
            if (this.backdropEl) {
                this.backdropEl.classList.remove(SHOW_BACKDROP);
            }
            if (this.animation) {
                this.animation.stop();
            }
            // emit close event
            this.ionDidClose.emit();
        }
    }

check video: Click here for streamable link

what is causing this?
any solution?

i have placed MENU to app.component.html

this is code:

<ion-app>
  <ion-menu [disabled]="this.profileService.profile.length === 0 || selectedRouter.includes('subscriptions-and-packages')" (ionDidOpen)="openMenu($event)" (ionDidClose)="closeMenu($event)" side="end" menuId="first" contentId="content1">
        <ion-header>
          <ion-toolbar>
            <ion-title>{{ 'menu' | translate }}</ion-title>
          </ion-toolbar>
        </ion-header>
        <ion-content>
          <ion-list>
          <ion-menu-toggle auto-hide="true">
            <ion-item lines="none" (click)="goToEditprprofileFromMenu()">
              <ion-avatar slot="start" style="width: 30px; height: 30px; margin-right: 25px;">
                <img *ngIf="profileService.profile.profile_pic !== null; else noProfilePicFound" src="{{profileImageAPILink}}{{profileService.profile.id}}/{{profileService.profile.profile_pic}}">
                <ng-template #noProfilePicFound>
                  <img src="/assets/new-admify-icons/usersingle.svg">
                </ng-template>
                </ion-avatar>
                <ion-label>{{ 'my_profile' | translate }}</ion-label>
            </ion-item>
            <ion-item (click)="goToSubsciptions()" lines="none">
                <ion-icon slot="start" src="assets/new-admify-icons/subscriptions-active.svg"></ion-icon>
                <ion-label>{{ 'subscriptions' | translate }}</ion-label>
            </ion-item>
            <ion-item lines="none"  (click)="addAFeedback($event)">
              <ion-icon slot="start" color="primary" src="assets/new-admify-icons/feedback.svg"></ion-icon>
              <ion-label>{{ 'feedback' | translate }}</ion-label>
            </ion-item>
        <ion-item lines="none"  (click)="logout()" style="color: black ">
          <ion-icon slot="start" color="danger" src="assets/new-admify-icons/logout-active.svg"></ion-icon>
          <ion-label>{{ 'logout' | translate }}</ion-label>
        </ion-item>
          </ion-menu-toggle>
          </ion-list>
        </ion-content>
      </ion-menu>
  <ion-router-outlet id="content1"></ion-router-outlet>
</ion-app>

Posts: 1

Participants: 1

Read full topic

Ionic-storage DB Dump, Backup

Ticks don't appear in ion-range

$
0
0

@leonardofmed wrote:

I’m trying to implement some functions that use ion-range as input. The functions are okay, my problem is related to the aesthetic issue of the ion-range element. Although there is this option to implement ticks in the documentation, when I insert it in my code nothing happens, the ion-range elements keep the same.

When I looked the code provided for the example using ticks, I saw that it don’t even use the option.

How can I obtain the ticks in the range element?

What I’m doing:

<ion-range min="1" max="2" step="0.20" value="1" snaps="true" ticks="true">
	<ion-icon size="small" slot="start" name="timer"></ion-icon>
	<ion-icon slot="end" name="timer"></ion-icon>
</ion-range>

Posts: 1

Participants: 1

Read full topic

Ionic Face Tracking

$
0
0

@GnomoMZ wrote:

Hello.

I was tasked with the job of implement real-time face tracking in a ionic APP.
The objective is to have it work similar to instagram.

I tried implementing two js libraries:

I need help and i am running out of ideas.

Posts: 1

Participants: 1

Read full topic

Viewing all 49300 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>