How to use the onsenui.platform.isAndroid function in onsenui

To help you get started, we’ve selected a few onsenui examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github ZencashOfficial / zencash-mobile / containers / AddLocation.js View on Github external
const AddLocation = ({actions}) => {
  let button;

  if (platform.isAndroid()) {
    button = (
      
      
      
    );
  } else {
    button = (
      <button>+ ADD LOCATION</button>
    );
  }

  return (
    <div></div>
github ZencashOfficial / zencash-mobile / containers / Location.js View on Github external
import {ListItem, Icon} from 'react-onsenui';

import {platform} from 'onsenui';

import * as Actions from '../actions';
import WeatherPage from './WeatherPage';
import WeatherIcon from '../components/WeatherIcon';
import {weatherCodeToColor} from '../util';

const styles = {
  weatherIcon: {
    color: '#fff',
    textAlign: 'center',
    width: platform.isAndroid() ? '36px' : '30px',
    height: platform.isAndroid() ? '36px' : '30px',
    lineHeight: platform.isAndroid() ? '36px' : '30px',
    borderRadius: '6px',
    fontSize: platform.isAndroid() ? '16px' : '14px'
  },
  buttons: {
    fontSize: '20px',
    color: '#cacaca'
  },
  refreshButton: {
    margin: '0 25px 0 0'
  },
  removeButton: {
    margin: '0 10px 0 0'
  }
};

const Location = ({
github ZencashOfficial / zencash-mobile / components / AddLocation.js View on Github external
const AddLocation = ({actions}) =&gt; {
  let button;

  if (platform.isAndroid()) {
    button = (
      
      
      
    );
  } else {
    button = (
      <button>Add location</button>
    );
  }

  return (
    <div></div>
github ZencashOfficial / zencash-mobile / components / Location.js View on Github external
{humidity}%
      
    );
  }

  let flag = country
    ? 
    : null;

  return (
     {
      actions.selectLocation(id);
      navigator.pushPage({component: WeatherPage});
    }} tappable&gt;
      <div>
        
      </div>
      <div>
        <div>
          {flag}
          {name}
        </div>
        <div>
          {subtitle}
        </div>
      </div>
      <div>
        <div> {
          e.stopPropagation();
          actions.fetchWeather(id);
        }} className='list__item__label'&gt;
          Refresh</div></div>