Quantcast
Channel: Ionic Forum - Latest topics
Viewing all 70435 articles
Browse latest View live

Ionic 4 D3 styling scss class

$
0
0

@BrentAshWilliams wrote:

Hi,

I am in the process of porting my app from ionic 3 to ionic 4. I use D3 for the creation of a meter. None of the styling is working. The entire meter is black. I am assuming it has something to do with lazy loading / shadow DOM.

The html is as follows:

<ion-header>
  <ion-toolbar>
    <ion-title>meter</ion-title>
  </ion-toolbar>
</ion-header>

<ion-content>
  <div #battery></div>
</ion-content>

This part of the code is for adding two posts to the top of the meter and where I try to add a scss class ‘battery-post’ to it:

og.selectAll('rect')
  .data([0.20, 0.80])
  .enter().append('rect')
  .attr('class', 'battery-post')
  .attr('x', function (d) {
    return rect.x + rect.width * d - config.postWidth / 2;
  })
  .attr('y', rect.y - config.postHeight)
  .attr('width', config.postWidth)
  .attr('height', config.postHeight)
  .attr('rx', config.postRx);

This is one of the scss classes for the two posts part of the meter at the top:

  .battery-post {
      fill: 'var(--ion-color-success)';
  }

And here is the result - all black. I highlighted the html for the two posts at the top where the rect has the battery-post on it which should fill the posts with -ion-color-success but it stays black:

<rect class="battery-post" x="226.3" y="2" width="25" height="8" rx="4"></rect>

Any thoughts or help on how to get the styling working would be great.

Thanks,

Brent

Posts: 4

Participants: 2

Read full topic


Webrtc video chat, session in Ionic 4

$
0
0

@nenadfemic wrote:

I am try to implement webrtc in ionic 4 application, but have problem with video streaming for remote user, always get local video streaming insted remote ?

this.connection.onstream = function(event) {		
		
		if(event.type === 'local') {
			localVideo.style.display = '';
			localVideo.controls = true;
			localVideo.srcObject = event.stream;
			localVideo.id = event.streamid;
		}
		if(event.type === 'remote') {
			remoteVideo.style.display = '';
			remoteVideo.controls = true;
			remoteVideo.srcObject = event.stream;
			remoteVideo.id = event.streamid;

		}
	};

So i wonder, is it any webrtc examples for implementing video session between more user in ionic.
I don’t want any paid solutions.

Posts: 1

Participants: 1

Read full topic

Bypass lockscreen on android and ios

$
0
0

@Emtwo wrote:

hi im tring to build a cordova music app and for that i need a way to overlay lock screen and show my own view there is it possible with cordova

Posts: 1

Participants: 1

Read full topic

How To Get Better At CSS

$
0
0

@Shmoji wrote:

I have been making an app for a while now and I have noticed a reoccurring issue. I do not seem to be getting any better at laying out my app in a pretty way which means I am not getting better at CSS I think.

For example, right now, I am trying to put a two labels at the top of my app with a ion-select beside each label. No matter how much I mess with the CSS I can not get it the way that I want it. I have both labels and ion-selects, but not in the aesthetic way I want.

This happens every time I try to change the visuals of my app and I just have to settle with some ugly interface.

My question is: how do I get better at CSS or how do I get better at interface design using CSS in Ionic? You would think practice would help, but it has not helped.

Posts: 4

Participants: 2

Read full topic

Ionic 4 Custom input inside

$
0
0

@mtarroyo wrote:

My application was created using the ionic-cli 5.0.2. I have the above structure for my form:

<ion-list>
    <ion-item>
        <ion-label>Password</ion-label>
        <password-input></password-input>
    </ion-item>
</ion-list>

Notice that password input consists into a custom element that I have created, wish is basically an <ion-input> with extra behaviors.

The thing is that the input is not properly rendering inside the <ion-item> due to the <password-input> tag that wraps it.

The recommendation for Ionic v3 is to put an item-content property to my custom tag but this is not working. I try to put slot="item-content" property but no success either.

Any thoughts or help on how to get the custom input working with list item would be great.

Thanks!

Posts: 1

Participants: 1

Read full topic

Ionic and angular grid not dynamic in android emulator?

$
0
0

@GeauxOnAndOn wrote:

My first post so first HELLO!!

I have a project, (ionic 5, angular7, cordova) that runs fine in the browser but not so happily in the android emulator. Main problem is I have a ion-grid attached to an angular array. I have buttons to delete rows and to insert rows. Doing this by modifying the bound array in angular. The screen does not update. I know the angular click works because I have other buttons tied to backend code and div s hide and show using ngIf .

Am I missing something or in android a grid will not update dynamically? what if I used standard table syntax and only use ionic components for visible td elements?

Posts: 2

Participants: 1

Read full topic

In App Purchase 2 vendor.js error

$
0
0

@plaidfox wrote:

Good Afternoon,

I’m currently working on trying to integrate In App Purchase 2 (https://ionicframework.com/docs/native/in-app-purchase-2) into my Ionic 3 app and have been running into some major issues. Since I couldn’t get it to work on my app that I’ve already built, I created a fresh app with only one additional page for testing. Try as I might (and I have tried) I cannot get the code to fully run without the following errors in xCode:

2019-06-10 13:19:06.998710-0400 IAP2 Test[7542:1096620] {“line”:76857,“column”:113,“sourceURL”:“ionic://localhost/build/vendor.js”}

2019-06-10 13:19:06.999433-0400 IAP2 Test[7542:1096620] Error Ordering {“line”:76780,“column”:133,“sourceURL”:“ionic://localhost/build/vendor.js”}

Does anyone have any suggestions on what I might try next or what the issue might be? Here are my specs:

ionic info
Ionic:
Ionic CLI          : 5.0.1 (/usr/local/lib/node_modules/ionic)
Ionic Framework    : ionic-angular 3.9.6
@ionic/app-scripts : 3.2.4

Cordova:
Cordova CLI       : 9.0.0 (cordova-lib@9.0.1)
Cordova Platforms : ios 4.5.5
Cordova Plugins   : cordova-plugin-ionic-keyboard 2.1.3, cordova-plugin-ionic-webview 4.0.1, (and 4 other plugins)

Utility:
cordova-res : 0.3.0
native-run  : 0.1.2

System:
ios-deploy : 1.9.4
ios-sim    : 8.0.1
NodeJS     : v10.15.3 (/usr/local/bin/node)
npm        : 6.4.1
OS         : macOS Mojave
Xcode      : Xcode 10.2.1 Build version 10E1001

npm outdated
Package                            Current  Wanted  Latest  Location
@angular/animations                 5.2.11  5.2.11   8.0.0  iap2Test
@angular/common                     5.2.11  5.2.11   8.0.0  iap2Test
@angular/compiler                   5.2.11  5.2.11   8.0.0  iap2Test
@angular/compiler-cli               5.2.11  5.2.11   8.0.0  iap2Test
@angular/core                       5.2.11  5.2.11   8.0.0  iap2Test
@angular/forms                      5.2.11  5.2.11   8.0.0  iap2Test
@angular/http                       5.2.11  5.2.11  7.2.15  iap2Test
@angular/platform-browser           5.2.11  5.2.11   8.0.0  iap2Test
@angular/platform-browser-dynamic   5.2.11  5.2.11   8.0.0  iap2Test
@ionic-native/core                  4.20.0  4.20.0   5.7.0  iap2Test
@ionic-native/splash-screen         4.20.0  4.20.0   5.7.0  iap2Test
@ionic-native/status-bar            4.20.0  4.20.0   5.7.0  iap2Test
cordova-plugin-ionic-webview         4.0.1   4.1.0   4.1.0  iap2Test
rxjs                                5.5.12  5.5.12   6.5.2  iap2Test

cordova plugin ls
cc.fovea.cordova.purchase 8.1.0 "Purchase"
cordova-plugin-device 2.0.2 "Device"
cordova-plugin-ionic-keyboard 2.1.3 "cordova-plugin-ionic-keyboard"
cordova-plugin-ionic-webview 4.0.1 "cordova-plugin-ionic-webview"
cordova-plugin-splashscreen 5.0.2 "Splashscreen"
cordova-plugin-statusbar 2.4.2 "StatusBar"
cordova-plugin-whitelist 1.3.3 "Whitelist"

Any help would be greatly appreciated.

Thank you.

Posts: 1

Participants: 1

Read full topic

Nav push not changing view in app component

$
0
0

@tgmosinn wrote:

So as the title says I have a menu on app.html, when I push with Nav I do get in the console log ionViewDidLoad but the page stays the same.

export class MyApp {
  
  @ViewChild(Nav) nav;
  rootPage:any = HomePage;
  constructor(platform: Platform, 
              statusBar: StatusBar, 
              splashScreen: SplashScreen  
              ) {
    platform.ready().then(() => {
      statusBar.show();
      splashScreen.hide();
      
      
    });
    
  }
  chat() {
    this.nav.push('ChatsPage');
  }

console log
ionViewDidLoad ChatsPage
I only get this in console log but page isn’t changing.

Posts: 3

Participants: 2

Read full topic


Ion-back-button defaultHref query string

$
0
0

@schallm wrote:

Is there a way to specify query string parameters for the defaultHref for the ion-back-button? I don’t see any properties that look promising.

I’m looking for something similar to the queryParams attribute of the RouterLink from angular.

Posts: 2

Participants: 2

Read full topic

Ionic serve context path

$
0
0

@makarchus wrote:

I am trying to use power of ionic as a progressive app, unfortunately I do not see any deployment option than firebase.

I would like to use my server and deploy ionic app as a web application with a URL context

unfortunlately when I do ionic serve it starts at localhost:8100 and I need to append a /<> as a context.

Is there a way in IONIC to do that?

Thank you in advance for your help and advise.

Posts: 1

Participants: 1

Read full topic

Ionic-webview disable on android

$
0
0

@powysm wrote:

Hi,
I am using cordova-plugin-ionic-webview in a cordova project. I only really want it for the ios wkwebview and not for the android platform, as i don’t need it there. I am aware that i could use plugman to only enable for ios.

However i have read that its possible to force the webview engine on ios wehttps://ionicframework.com/docs/v3/wkwebview/#option-1-force-uiwebview-usage.

My question is it possible to force default webview in Android?
Many Thanks
Mathew

Posts: 1

Participants: 1

Read full topic

Error 404 reloading a page of a PWA

$
0
0

@ioclaudio wrote:

Hi,
I’ve done a PWA with Ionic4.
It is installed behind an Apache server.
It seems to work, that is I can navigate through the pages of the site, but if I reload a page than a 404 error appears.
For example, if I navigate to the page

http://my.site.com/login

it works well, but if I reload the page with F5, for example, then I have the error:

Not Found
The requested URL /login was not found on this server.

What could be the error?
A misconfiguration of Apache?

Thank you very much

cld

Posts: 2

Participants: 1

Read full topic

Ionic v1 app - No Internet Connection

$
0
0

@rgecy wrote:

I have a v1 app that is getting a popup message in android emulator or on android device that there is no internet connection. I am also noticing that the $ionicplatform.ready event is not firing. If I run it in the browser, everything works fine.

The app was working fine until we update npm, ionic and cordova libraries after ionic did away ionic cloud.

I have the cordova whitelist plugin installed and http-equiv Content-Security-Policy set to default-src *.

Any suggestions on where to start. This is really frustrating since its pretty much the exact same code was working before we updated. I have even created a new app so all the libraries were new and still no internet.

Thanks,

Robert

Posts: 1

Participants: 1

Read full topic

Ionic reverts to an older version on my development device after a while

$
0
0

@DMoney wrote:

I’m having a huge issue with Ionic that I’m not able to get any answers in regards to a resolution.

I’m developing an Ionic 4 app using Firebase. I’m plugging my Android into my MAC and running ionic cordova run android to deploy to my Samsung to test it on the device. What’s been happening the last month is when I make code updates and deploy, it will randomly revert back to an older deployment on my phone. So when I open it again it won’t have any of the new features I’ve added. This is really frustrating and I haven’t gotten any answers on Ionic’s site. And not to mention I get this email from Ionic that I don’t know what it means given I’m only deploying to my phone.

Hello,
Congratulations on growing your app user base. We’re thrilled to see your continued growth and success in the app stores!
This email is to notify that you’ve reached 70% of your Deploy limit. Here’s a summary of your current plan and usage:
Current plan: Starter
Monthly Deploy limit with your current plan: 100
Current monthly Deploy count: 63
To reflect and support your ongoing growth, you will need to upgrade your subscription to the Starter Add-On. This will increase your Deploy limit tier to10000, allowing you to continue to push to your entire monthly active user base.

Posts: 1

Participants: 1

Read full topic

Ionic-4 : Need Help with ModalController

$
0
0

@SAT77 wrote:

If I open modal1, modal2, modal3. On modal3 I decided to dismiss all previous modals.

How can I dismiss all previous modals (modal3-modal2-modal1) ?

Posts: 2

Participants: 2

Read full topic


Trouble viewing List items in Ionic 4

$
0
0

@SooperFly wrote:

In one of my projects I’m attempting to create a list of items and once a user presses on an item, they will be navigated to a new page where the Item’s details will be shown. It’s very simple and straightforward, the Item’s name and it’s details are already written on the first page and I want them to be transferred to the next page. However I keep getting the error: Argument of type ‘{ item: any; }’ is not assignable to parameter of type 'NavigationOptions

here is my code as follows: This is the main page in where the list of all items will be shown

Html

<ion-list>
<ion-item *ngFor="let item of items" (click)="viewItem(item)"><ion-card>
<ion-card-header>
<ion-card-subtitle></ion-card-subtitle>
<ion-card-title>{{item.title}}</ion-card-title>
</ion-card-header>

<ion-card-content>
{{item.description}}
</ion-card-content>
</ion-card></ion-item>
</ion-list>

TS

export class ShoppingPage implements OnInit {
  public item;
  constructor( public navCtrl: NavController ) { }

  ngOnInit() {
  }
  ionViewWillEnter(){
  this.item = [
      {title: 'Product 1', description: 'This is where we would would put the description of "product 1"'},
      {title: 'Product 2', description: 'This is how the description of Product 2 would look'},
      {title: 'Product 3', description: "Product 3 is the greatest product you can buy off the market because it's perfect"}
    ];
  }
  viewItem(item){
    this.navCtrl.navigateForward('item-detail', {
      item: item
    });
  }

}

Now here is the code of the page in where I require all the data to be shown:

html

<ion-header>
  <ion-toolbar>
    <ion-title>{{title}}</ion-title>
  </ion-toolbar>
</ion-header>

<ion-content>
{{description}}
</ion-content>

TS

export class ItemDetailPage implements OnInit {
  title;
  description;
  constructor(public navParams: NavParams) { }
  ionViewDidLoad(){
    this.title = this.navParams.get('item').title;
    this.description = this.navParams.get('item').description;
  }
  ngOnInit() {
  }

}

Thank you

EDIT: I am using ionic 4

Posts: 1

Participants: 1

Read full topic

Ionic Studio not updating image src

$
0
0

@jdhunter wrote:

There seems to be a serious problem with Ionic Studio. I create a new Tab app, and simply run it. Great, all is well. I change the image reference to a different image that I added to the assets folder, but the original one still displays. I stop the NG Serve and restart, the same old image displays. I rename the files (in src/assets and www/assets) of the original file so that the old reference is now bad, and rebuild/re-run and still it displays the old image that no longer even exists. No matter what I do (multiple computers), this happens. So, I have been doing web development since the inception of the web, and I am still an avid fan of Creator, can work wonders with it. But I can’t seem to get out of the starting gate with Studio. Am I simply wasting my money on it? Does it work for anyone else?

Posts: 2

Participants: 1

Read full topic

Ip camera add with ionic project

$
0
0

@krishkk wrote:

Hey , anyone implemented Ip camera functionality with ionic . I only want to add my Ip camera with communities.

Posts: 1

Participants: 1

Read full topic

Ionic row with 4 columns in same row

Ionic 4 modal call on same page

$
0
0

@amjayesh07 wrote:

I added modal as described above, Right now i added the whole page, where modal is called.
But i want to show only particular part of html of same page where modal caled in modal,
How can i do that.

Below is my code

import { Component, OnInit } from '@angular/core';
import { ModalController } from '@ionic/angular';



@Component({
  selector: 'app-search',
  templateUrl: './search.page.html',
  styleUrls: ['./search.page.scss'],
})

export class SearchPage implements OnInit {

  constructor(private modalController: ModalController) { }

  ngOnInit() {
  }

  async openModal() {
    const modal = await this.modalController.create({
      component: SearchPage,
      componentProps: { 
        foo: 'hello',
        bar: 'world'
      }
    });
    return await modal.present();
  }
}

For more info see image, on click of product listing, i want to call modal where i can show product details info.

Posts: 1

Participants: 1

Read full topic

Viewing all 70435 articles
Browse latest View live


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