Example Ionic framework app with slide menu and google javascript maps embedded
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var Currency = React.createClass({ | |
| propTypes: { | |
| amount: React.PropTypes.number, | |
| currencyCode: React.PropTypes.string, | |
| decimalPlaces: React.PropTypes.number | |
| }, | |
| formatCurrency: function (x, decimalPlaces, decimalSeparator, groupSeparator) { | |
| var parts = x.toString().split('.'); | |
| parts[0] = parts[0].replace(/\B(?=(\d{3})+(?!\d))/g, groupSeparator); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| function formatCurrency(x, decimalPlaces, decimalSeparator, groupSeparator) { | |
| var parts = x.toString().split("."); | |
| parts[0] = parts[0].replace(/\B(?=(\d{3})+(?!\d))/g, groupSeparator); | |
| if(parts.length > 1) { | |
| parts[1] = parts[1].substring(0, decimalPlaces); | |
| } else { | |
| parts[1] = '000000000'.substring(0, decimalPlaces); | |
| } | |
| return parts.join(decimalSeparator); | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # All purpose minimalistic random generator | |
| def random(params) | |
| if(params.kind_of?(Array)) | |
| return params[rand(params.size)] | |
| end | |
| if(params.kind_of?(Range)) | |
| return (rand(params.end - params.begin) + params.begin).to_s | |
| end | |
| if(params.kind_of?(Integer)) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| require 'thread' | |
| require 'date' | |
| # Format number of hours, minutes and seconds since start time: | |
| def elapsed_time_formatted(start_time) | |
| end_time = DateTime.now | |
| total_seconds = ((end_time - start_time) * 24 * 60 * 60).to_i | |
| seconds = total_seconds % 60 | |
| minutes = (total_seconds / 60) % 60 | |
| hours = total_seconds / (60 * 60) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import React, { ReactDOM, Component, PropTypes } from 'react'; | |
| import {render} from 'react-dom'; | |
| import { Router, Route, Link, browserHistory} from 'react-router' | |
| /** React router hello world example **/ | |
| class App extends Component { | |
| render() { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| object { | |
| transform-origin: 0 0; | |
| transform: rotate(15deg) translateX(230px) scale(1.5, 2.6) skew(220deg, -150deg) translateX(230px) | |
| } | |
| #object { | |
| transform-origin: 0 0; | |
| transform: matrix(1.06, 1.84, 0.54, 2.8, 466px, 482px) | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #object { | |
| transform-origin: 0 0; | |
| transform: rotate(15deg) translateX(230px) scale(1.5, 2.6) skew(220deg, -150deg) translateX(230px) | |
| } | |
| #object { | |
| transform-origin: 0 0; | |
| transform: matrix(1.06, 1.84, 0.54, 2.8, 466px, 482px) | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <link rel="import" href="../topeka-elements/category-images.html"> | |
| <link rel="import" href="../core-icon/core-icon.html"> | |
| <link rel="import" href="../core-icon-button/core-icon-button.html"> | |
| <link rel="import" href="../core-toolbar/core-toolbar.html"> | |
| <link rel="import" href="../core-header-panel/core-header-panel.html"> | |
| <link rel="import" href="../core-icons/core-icons.html"> | |
| <link rel="import" href="../core-icons/av-icons.html"> | |
| <link rel="import" href="../paper-fab/paper-fab.html"> | |
| <link rel="import" href="../core-menu-button/core-menu-button.html"> | |
| <link rel="import" href="../core-item/core-item.html"> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| (function (root, $$, _, Backbone) { | |
| "use strict"; | |
| /* | |
| backgrid | |
| http://github.com/wyuenho/backgrid | |
| Copyright (c) 2013 Jimmy Yuen Ho Wong and contributors | |
| Licensed under the MIT @license. | |
| */ |
NewerOlder