JSPM

  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 11
  • Score
    100M100P100Q47775F
  • License MIT

Calculate the volume for your move

Package Exports

  • moving-volume-calculator

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (moving-volume-calculator) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

Moving Volume Calculator (Demo)

Calculate the volume for your move

Doc

  • Installation

Simply import MovingVolumeCalculator into your HTML.

<link rel="stylesheet" type="text/css" href="https://gitcdn.link/repo/Zenoo/moving-volume-calculator/master/MovingVolumeCalculator.min.css">
<script src="https://gitcdn.link/repo/Zenoo/moving-volume-calculator/master/MovingVolumeCalculator.min.js"></script>	
  • How to use

Create a new MovingVolumeCalculator object with a query String or an Element as the first parameter :

let movingVolumeCalculator = new MovingVolumeCalculator('div.with[any="selector"]', options);
// OR
let element = document.querySelector('li.terally[any="thing"]');
let movingVolumeCalculator = new MovingVolumeCalculator(element, options);
  • Options
{
    lang: 'en', // Language to use
    surfaceToVolumeRatio: 0.45, // Default surface to volume ratio
    stylised: true, // Use the default Calculator theme
    rooms: { // See https://zenoo.github.io/moving-volume-calculator/MovingVolumeCalculator.html#.Rooms
        kitchen: {
            icon: 'https://your.icon',
            lang: {
            en: 'Kitchen',
            fr: 'Cuisine'
            },
            surface: 14,
            ratio: 0.45
        }, ...
    },
    dictionary: {// See https://zenoo.github.io/moving-volume-calculator/MovingVolumeCalculator.html#.Dictionary
        en: {
            roomsOptionEnable: 'I prefer filling out my rooms\' details',
            roomsOptionDisable: 'I\'d rather fill out my surface'
        },
        fr: {
            roomsOptionEnable: 'Je préfère renseigner le détail de mes pièces',
            roomsOptionDisable: 'Je préfère renseigner ma surface'
        }
    }
}
  • Methods

See the documentation for the method definitions.

  • Example

See this JSFiddle for a working example

Authors