Questions tagged [onsen-ui]

Onsen UI is a front-end framework for developing hybrid mobile apps in HTML5. It supports both Flat and Material Design and is framework agnostic.

Onsen UI provides a set of UI components for developing hybrid mobile apps in HTML5. It is built on top of Web Components and is compatible with any framework such as AngularJS, Angular 2, React, Vue, etc.

Before asking a question please take a look at the documentation since a lot of questions already are answered there.

Onsen UI is an open source project and the code is available on GitHub. It's released under the Apache license.

1153 questions
3
votes
1 answer

How to download a file using Cordova File Transfer plugin in iOS

I have used the following code to download file: $scope.onDownloadMusic = function( live ) { var downloadUrl = offlineUrl + fileName; var hostUrl = encodeURI(live.url); var fileTransfer = new FileTransfer(); fileTransfer.download( …
Nakket
  • 620
  • 7
  • 18
3
votes
2 answers

Angular variable not binding to view

I have an Angular/Onsen app that has an image which is put into a HTML5 canvas tag, and I am picking the color of the pixel I am on on hover. The view is pretty simple:
jesses.co.tt
  • 2,689
  • 1
  • 30
  • 49
3
votes
1 answer

Custom modifier in onsen UI

I am using Onsen UI in my Cordova project, how is it possible to make custom modifier like chevron, tappable etc? In documentation it is nothing about this http://onsen.io/guide/overview.html#UsingModifier I want to make theme switcher and load…
Kicker
  • 606
  • 1
  • 12
  • 27
3
votes
0 answers

onclick event trigger several times Onsen UI Angular + JQuery

what is wrong with this code? $(document).on("click",".item-from-list",function(){ It works fine. But after I use navigator.replacePage(); It triggers the same time that I used replacePage(); Eg: I have a button that user select a day and it…
Dyego Oviedo
  • 308
  • 4
  • 15
3
votes
1 answer

How to left align photos when choosing image in gallery using wymsee imagepicker

Thanks to wymsee/imagePicker, I can easily get image picking feature work in my apps built with Onsen UI. But then I am facing the inconsistency UI issue on different platforms, which is that photos isn't left aligned in iOS platform. Example Image:…
3
votes
1 answer

jquery click event not triggered in ons-back-button in onsenui

With the latest version of Onsen v1.3.8, I couldn't write specific jquery click events for ons-back-button like below. $(document).on('click', 'ons-back-button', function(e){ alert('clicked'); }); But, with the older versions like /* onsenui -…
UI_Dev
  • 3,317
  • 16
  • 46
  • 92
3
votes
1 answer

onsen navigator popPage, reload previous controller

Suppose I've 2 controllers - C1 and C2. I do a navigator.pushPage from v1.html to v2.html. And then I do a navigator.popPage on v2.html. But the popPage doesn't reload the controller C1. I'm trying to figure out a way to reload the controller, but…
Rohit Jain
  • 209,639
  • 45
  • 409
  • 525
3
votes
2 answers

Javascript not working in Pushed Page of ons-page Onsen UI

I'm using Cordova/PhoneGap and Onsen UI. I have two html pages. Switch(pushpage) button is working perfect. But Javascript not working in search.html Here is my code: index.html (Default Main Page) search.html index.html ...
user1999
  • 87
  • 1
  • 10
3
votes
2 answers

Create Onsen UI elements dynamically

Is it possible to create Onsen UI elements dynamically using JavaScript? The official documentation says nothing about it.
Anina
  • 453
  • 3
  • 18
3
votes
1 answer

Onsen UI ons.notification.alert issue

the following code var i=0; i++; ons.notification.alert({message: i}); i++; ons.notification.alert({message: i}); i++; ons.notification.alert({message: i}); The alert result is: 3 2 1 Could someone please explain the mechanism of Onsen…
Paul
  • 437
  • 2
  • 14
3
votes
1 answer

Content-Security-Policy error https://ssl.gstatic.com

I am getting an error as captured in the screenshot below: It reads: Refused to evaluate a string as JavaScript because 'unsafe-eval' is not an allowed source of script in the following Content Security Policy directive: "default-src file: data:…
3
votes
1 answer

How to initialize subpage when i pushPage to it

in my index.html
test
When I click it will pushPage to Test.html but: How to run my initialize code in Test.html ? I tried to write them…
Lemon
  • 55
  • 3
3
votes
1 answer

How to implement two slide-menu on both sides of a page in Onsen-UI?

I'm new to Onsen-UI and would like to have slide-menus on both sides of my page. I intend to have multiple pages that will have this functionality and dont know how I can implement that. What is the best way to do that?
3
votes
1 answer

Reload and check if user got connected to phonegap using angularjs

i am using phonegap to create an app. I am successful to check if the user is connected to internet or not. But If the user is not connected. I want to put a button so user can click on reload and page will be reloaded. Here is how my code looks…
user3201500
  • 1,538
  • 3
  • 22
  • 43
3
votes
1 answer

Onsen UI Pagination: navigator and tabbar

I am in doubt about mixing navigator and tabbar. Explaining: the main page (Main page1) consists of two child pages (tab1 and tab2) that are accessed by tabbar, while the other pages (page2 and 3) are accessed through the navigator. The tab1 page is…