React Measurement
Measurement for React
Measurement for React
Measurement for React
Learn about MeasurementMeasurement - Distance
mobiscroll.settings = {
theme: '',
lang: ''
};
class DistanceDemo extends React.Component {
render() {
return (
<div>
<mobiscroll.Form>
<mobiscroll.FormGroup>
<mobiscroll.FormGroupTitle>Inside Mobiscroll Form</mobiscroll.FormGroupTitle>
<label>
Miles
<mobiscroll.Distance
ref="distance"
units={['mi']}
placeholder="Please Select..."
/>
</label>
<label>
Kilometers
<mobiscroll.Distance
ref="distance"
units={['km']}
placeholder="Please Select..."
/>
</label>
<label>
Convert
<mobiscroll.Distance
ref="distance"
units={['km', 'mi']}
step={0.5}
max={800}
placeholder="Please Select..."
/>
</label>
</mobiscroll.FormGroup>
<mobiscroll.FormGroup className="mbsc-padding">
<p className="mbsc-thin">Use it on any input or non-mobiscroll form.</p>
</mobiscroll.FormGroup>
</mobiscroll.Form>
<div className="demo-container">
<mobiscroll.Distance
ref="distance"
className="demo-non-form"
placeholder="Please Select..."
/>
</div>
</div>
);
}
}
<div id="content">
.demo-non-form {
width: 100%;
margin: 0 0 5px 0;
padding: 10px;
border: 1px solid #ccc;
border-radius: 0;
font-family: arial, verdana, sans-serif;
font-size: 14px;
box-sizing: border-box;
-webkit-appearance: none;
}
.demo-container {
padding: 0 1em;
}
Measurement - Speed
mobiscroll.settings = {
theme: '',
lang: ''
};
class SpeedDemo extends React.Component {
render() {
return (
<div>
<mobiscroll.Form>
<mobiscroll.FormGroup>
<mobiscroll.FormGroupTitle>Inside Mobiscroll Form</mobiscroll.FormGroupTitle>
<label>
Mph
<mobiscroll.Speed
ref="speed"
units={['mph']}
placeholder="Please Select..."
/>
</label>
<label>
Kmh
<mobiscroll.Speed
ref="speed"
units={['kph']}
placeholder="Please Select..."
/>
</label>
<label>
Convert
<mobiscroll.Speed
ref="speed"
units={['kph', 'mph']}
step={0.5}
max={800}
placeholder="Please Select..."
/>
</label>
</mobiscroll.FormGroup>
<mobiscroll.FormGroup className="mbsc-padding">
<p className="mbsc-thin">Use it on any input or non-mobiscroll form.</p>
</mobiscroll.FormGroup>
</mobiscroll.Form>
<div className="demo-container">
<mobiscroll.Speed
ref="speed"
className="demo-non-form"
placeholder="Please Select..."
/>
</div>
</div>
);
}
}
<div id="content">
.demo-non-form {
width: 100%;
margin: 0 0 5px 0;
padding: 10px;
border: 1px solid #ccc;
border-radius: 0;
font-family: arial, verdana, sans-serif;
font-size: 14px;
box-sizing: border-box;
-webkit-appearance: none;
}
.demo-container {
padding: 0 1em;
}
Measurement - Temperature
mobiscroll.settings = {
theme: '',
lang: ''
};
class TemperatureDemo extends React.Component {
render() {
return (
<div>
<mobiscroll.Form>
<mobiscroll.FormGroup>
<mobiscroll.FormGroupTitle>Inside Mobiscroll Form</mobiscroll.FormGroupTitle>
<label>
Celsius
<mobiscroll.Temperature
ref="temp"
units={['c']}
placeholder="Please Select..."
/>
</label>
<label>
Fahrenheit
<mobiscroll.Temperature
ref="temp"
units={['f']}
placeholder="Please Select..."
/>
</label>
<label>
Convert
<mobiscroll.Temperature
ref="temp"
units={['c', 'f']}
max={100}
placeholder="Please Select..."
/>
</label>
</mobiscroll.FormGroup>
<mobiscroll.FormGroup className="mbsc-padding">
<p className="mbsc-thin">Use it on any input or non-mobiscroll form.</p>
</mobiscroll.FormGroup>
</mobiscroll.Form>
<div className="demo-container">
<mobiscroll.Temperature
ref="temp"
className="demo-non-form"
placeholder="Please Select..."
/>
</div>
</div>
);
}
}
<div id="content">
.demo-non-form {
width: 100%;
margin: 0 0 5px 0;
padding: 10px;
border: 1px solid #ccc;
border-radius: 0;
font-family: arial, verdana, sans-serif;
font-size: 14px;
box-sizing: border-box;
-webkit-appearance: none;
}
.demo-container {
padding: 0 1em;
}
Measurement - Mass
mobiscroll.settings = {
theme: '',
lang: ''
};
class MassDemo extends React.Component {
render() {
return (
<div>
<mobiscroll.Form>
<mobiscroll.FormGroup>
<mobiscroll.FormGroupTitle>Inside Mobiscroll Form</mobiscroll.FormGroupTitle>
<label>
Kilograms
<mobiscroll.Mass
ref="mass"
units={['kg']}
placeholder="Please Select..."
/>
</label>
<label>
Pounds
<mobiscroll.Mass
ref="mass"
units={['lb']}
placeholder="Please Select..."
/>
</label>
<label>
Convert
<mobiscroll.Mass
ref="mass"
units={['kg', 'lb']}
max={100}
placeholder="Please Select..."
/>
</label>
</mobiscroll.FormGroup>
<mobiscroll.FormGroup className="mbsc-padding">
<p className="mbsc-thin">Use it on any input or non-mobiscroll form.</p>
</mobiscroll.FormGroup>
</mobiscroll.Form>
<div className="demo-container">
<mobiscroll.Mass
ref="mass"
className="demo-non-form"
placeholder="Please Select..."
/>
</div>
</div>
);
}
}
<div id="content">
.demo-non-form {
width: 100%;
margin: 0 0 5px 0;
padding: 10px;
border: 1px solid #ccc;
border-radius: 0;
font-family: arial, verdana, sans-serif;
font-size: 14px;
box-sizing: border-box;
-webkit-appearance: none;
}
.demo-container {
padding: 0 1em;
}
Measurement - Force
mobiscroll.settings = {
theme: '',
lang: ''
};
class ForceDemo extends React.Component {
render() {
return (
<div>
<mobiscroll.Form>
<mobiscroll.FormGroup>
<mobiscroll.FormGroupTitle>Inside Mobiscroll Form</mobiscroll.FormGroupTitle>
<label>
Newton
<mobiscroll.Force
ref="force"
units={['N']}
placeholder="Please Select..."
/>
</label>
<label>
Pound-force
<mobiscroll.Force
ref="force"
units={['lbf']}
placeholder="Please Select..."
/>
</label>
<label>
Convert
<mobiscroll.Force
ref="force"
units={['N', 'lbf']}
max={100}
placeholder="Please Select..."
/>
</label>
</mobiscroll.FormGroup>
<mobiscroll.FormGroup className="mbsc-padding">
<p className="mbsc-thin">Use it on any input or non-mobiscroll form.</p>
</mobiscroll.FormGroup>
</mobiscroll.Form>
<div className="demo-container">
<mobiscroll.Force
ref="force"
className="demo-non-form"
placeholder="Please Select..."
/>
</div>
</div>
);
}
}
<div id="content">
.demo-non-form {
width: 100%;
margin: 0 0 5px 0;
padding: 10px;
border: 1px solid #ccc;
border-radius: 0;
font-family: arial, verdana, sans-serif;
font-size: 14px;
box-sizing: border-box;
-webkit-appearance: none;
}
.demo-container {
padding: 0 1em;
}
Measurement - Convert Currency
class MeasurementDemo extends React.Component {
render() {
return (
<div>
<mobiscroll.Measurement
ref="measurement"
theme=""
lang=""
units={['EUR', 'USD', 'GBP', 'CHF']}
defaultUnit="EUR"
min={0}
max={150}
step={0.05}
convert={function (val, unit1, unit2) {
var multipliers = {
EUR: 1,
GBP: 0.772,
CHF: 1.105,
USD: 1.110
};
return val * multipliers[unit2] / multipliers[unit1];
}}
placeholder="Please Select..."
/>
</div>
);
}
}
<div id="content">
Measurement - Currency
class MeasurementDemo extends React.Component {
render() {
return (
<div>
<mobiscroll.Measurement
ref="measurement"
theme=""
lang=""
units={['EUR', 'USD', 'GBP', 'CHF']}
defaultUnit="EUR"
min={0}
max={1000}
step={0.05}
convert={false}
minWidth={72}
placeholder="Please Select..."
/>
</div>
);
}
}
<div id="content">
Measurement - Event handlers
EVENTS FIRED:
class MeasurementDemo extends React.Component {
onInit = (event, inst) => {
// Your custom event handler goes here
}
onMarkupReady = (event, inst) => {
// Your custom event handler goes here
}
onBeforeShow = (event, inst) => {
// Your custom event handler goes here
}
onPosition = (event, inst) => {
// Your custom event handler goes here
}
onShow = (event, inst) => {
// Your custom event handler goes here
}
onSet = (event, inst) => {
// Your custom event handler goes here
}
onItemTap = (event, inst) => {
// Your custom event handler goes here
}
onDestroy = (event, inst) => {
// Your custom event handler goes here
}
onClose = (event, inst) => {
// Your custom event handler goes here
}
onChange = (event, inst) => {
// Your custom event handler goes here
}
onCancel = (event, inst) => {
// Your custom event handler goes here
}
onBeforeClose = (event, inst) => {
// Your custom event handler goes here
}
onClear = (event, inst) => {
// Your custom event handler goes here
}
render() {
return (
<div>
<mobiscroll.Measurement
ref="measurement"
theme=""
lang=""
onInit={this.onInit}
onMarkupReady={this.onMarkupReady}
onBeforeShow={this.onBeforeShow}
onPosition={this.onPosition}
onShow={this.onShow}
onSet={this.onSet}
onItemTap={this.onItemTap}
onDestroy={this.onDestroy}
onClose={this.onClose}
onChange={this.onChange}
onCancel={this.onCancel}
onBeforeClose={this.onBeforeClose}
onClear={this.onClear}
placeholder="Please Select..."
/>
</div>
);
}
}
<div id="content"></div>
Measurement - Display modes
mobiscroll.settings = {
lang: '',
theme: ''
};
class MeasurementDemo extends React.Component {
render() {
return (
<mobiscroll.Form>
<mobiscroll.FormGroup>
<mobiscroll.FormGroupTitle>Try different display modes</mobiscroll.FormGroupTitle>
<label>
Bottom
<mobiscroll.Measurement
display="bottom"
placeholder="Please Select..."
/>
</label>
<label>
Top
<mobiscroll.Measurement
display="top"
placeholder="Please Select..."
/>
</label>
<label>
Center
<mobiscroll.Measurement
display="center"
placeholder="Please Select..."
/>
</label>
<label>
Bubble
<mobiscroll.Measurement
display="bubble"
placeholder="Please Select..."
/>
</label>
</mobiscroll.FormGroup>
<mobiscroll.FormGroup className="mbsc-padding">
<p className="mbsc-thin">With inline display you can embed the Measurement component in almost any markup or form.</p>
</mobiscroll.FormGroup>
<mobiscroll.FormGroup>
<mobiscroll.FormGroupTitle>Embedded measurement scroller</mobiscroll.FormGroupTitle>
<mobiscroll.Measurement
type="hidden"
display="inline"
/>
</mobiscroll.FormGroup>
</mobiscroll.Form>
);
}
}
<div id="content"></div>
Measurement - Theming capabilities
mobiscroll.settings = {
theme: '',
lang: ''
};
class MeasurementDemo extends React.Component {
render () {
return (
<mobiscroll.Form>
<div className="mbsc-grid-fixed mbsc-grid-lg">
<div className="mbsc-row">
<div className="mbsc-col">
<mobiscroll.FormGroup inset>
<mobiscroll.FormGroupTitle>iOS Theme</mobiscroll.FormGroupTitle>
<label>
Light
<mobiscroll.Measurement
theme="ios"
placeholder="Please Select..."
/>
</label>
<label>
Dark
<mobiscroll.Measurement
theme="ios-dark"
placeholder="Please Select..."
/>
</label>
</mobiscroll.FormGroup>
</div>
<div className="mbsc-col">
<mobiscroll.FormGroup inset>
<mobiscroll.FormGroupTitle>Material Theme</mobiscroll.FormGroupTitle>
<label>
Light
<mobiscroll.Measurement
theme="material"
placeholder="Please Select..."
/>
</label>
<label>
Dark
<mobiscroll.Measurement
theme="material-dark"
placeholder="Please Select..."
/>
</label>
</mobiscroll.FormGroup>
</div>
</div>
<div className="mbsc-row">
<div className="mbsc-col">
<mobiscroll.FormGroup inset>
<mobiscroll.FormGroupTitle>Windows Theme</mobiscroll.FormGroupTitle>
<label>
Light
<mobiscroll.Measurement
theme="windows"
placeholder="Please Select..."
/>
</label>
<label>
Dark
<mobiscroll.Measurement
theme="windows-dark"
placeholder="Please Select..."
/>
</label>
</mobiscroll.FormGroup>
</div>
<div className="mbsc-col">
<mobiscroll.FormGroup inset>
<mobiscroll.FormGroupTitle>Mobiscroll Theme</mobiscroll.FormGroupTitle>
<label>
Light
<mobiscroll.Measurement
theme="mobiscroll"
placeholder="Please Select..."
/>
</label>
<label>
Dark
<mobiscroll.Measurement
theme="mobiscroll-dark"
placeholder="Please Select..."
/>
</label>
</mobiscroll.FormGroup>
</div>
</div>
</div>
</mobiscroll.Form>
);
}
}
<div id="content"></div>
Looking for something you didn't see or have a sales question?
Ask us about it, we're here to help.
Component license
Purchase component licenses if you are looking for specific funcionality.
All
Framework license
Get all 36 components, including
Framework license
Get all 36 components, including
- Use it when building with plain and simple JS
- Compatible with vanilla JS app or frameworks like Vue
- Royalty-free commercial usage
- Technical support is included with the license
- Use it with jQuery and jQuery Mobile
- Enjoy the familiar API if you already use jQuery
- Royalty-free commercial usage
- Technical support is included with the license
- Use it with Angular JS and Ionic 1
- For web and mobile apps based on Angular 1.x
- Royalty-free commercial usage
- Technical support is included with the license
- Use it with Angular 2/4/5/6/7 and Ionic 2/3/4
- Visual Studio and VS Code integration
- Royalty-free commercial usage
- Technical support is included with the license
- Use it when building with React JS
- Collection of UI components for web and mobile
- Royalty-free commercial usage
- Technical support is included with the license
Framework license
Select the development framework you are using. Get all 36 components with the license.
- Use it when building with plain and simple JS
- Compatible with vanilla JS app or frameworks like Vue
- Royalty-free commercial usage
- Technical support is included with the license
- Use it with jQuery and jQuery Mobile
- Enjoy the familiar API if you already use jQuery
- Royalty-free commercial usage
- Technical support is included with the license
- Use it with Angular JS and Ionic 1
- For web and mobile apps based on Angular 1.x
- Royalty-free commercial usage
- Technical support is included with the license
- Use it with Angular 2/4/5/6/7 and Ionic 2/3/4
- Visual Studio and VS Code integration
- Royalty-free commercial usage
- Technical support is included with the license
- Use it when building with React JS
- Collection of UI components for web and mobile
- Royalty-free commercial usage
- Technical support is included with the license
Select the framework you are interested in
Use Javascript when building with plain and simple JS.
Use jQuery when you have jQuery already included or if you are building with jQuery Mobile.
Use AngularJS when building with Angular 1.x or Ionic 1.
Use Angular when building with Angular 2/4/5/6/7 or Ionic 2/3/4.
Use it when you are building your app or website with React.
Do you need additional support seats?
The framework license comes with one support seat. ( +$50/seat )
Add the source code?
What framework are you using?
We have to set you up with a trial for this to run 👍
What framework are you using?
Step 1.Install the Mobiscroll CLI from npm
$ npm install -g @mobiscroll/cli
The CLI makes configuring your apps super simple 👍
Step 2.Run the following command in the root folder of your Ionic project
$ mobiscroll config ionic
$ mobiscroll config ionic --lite
You will be prompted to log in with your mobiscroll account. Set your password here
Create an Ionic 3 & Mobiscroll starter with the CLI:
Run this command for Ionic 4 & Mobiscroll starter:
Extract the zip file and run the project like any Ionic app. Make sure to have Ionic CLI installed and open the terminal in the app root folder.
$ npm install
$ ionic serve
Let us know if we can help and enjoy!
Your password has been changed!
Everything is set up so that you can dig in right away and start exploring.
We have set up a trial so that you can try the demos locally.
Extract the zip file and open the demo in your favorite browser.
To install Mobiscroll in your project
follow instructions from this page.
Let us know if we can help and enjoy! 👍
Please extract the zip file and run the project like any Angular CLI app.
Make sure to have the Angular CLI installed.
For installation and usage, extract the zip file and open a terminal window and follow these steps.
$ npm install
$ ng serve --open
Let us know if we can help and enjoy! 👍
Everything is set up so that you can dig in right away and start exploring.
We have set up a trial so that you can try the demos locally.
The easiest way to get started is to follow the installation steps and by
grabbing the code directly from the demo page. Let us know if we can help and enjoy!
You'll find a fully functional Kitchen-sink Ionic app in the zip file.
Everything is set up so that you can dig in right away and start exploring.
We have set up a trial so that you can try the demos locally.
The demos are using Babel's in-browser ES6 and JSX transformer.
Extract the zip file and open the demo in your browser. To install Mobiscroll in your project
follow instructions from this page.
Let us know if we can help and enjoy! 👍