mirror of
https://github.com/publiclab/image-sequencer.git
synced 2025-12-11 19:00:00 +01:00
* Add manifest.json and cache static assets for offline use (#331)
* Add manifest.json
* cache static assets for offline use
* update cache
* add meta theme-color and change static files to be cache
* cache the files on network request
* caching on first run
Signed-off-by: tech4GT <varun.gupta1798@gmail.com>
* add a button to clear cache
* add styling to clear cache link
* Update Modules.js (#452)
I've arranged the modules in alphabetical order.
* Added a function to parse Input coordinates and added the functionality for crop and overlay modules
* Added changed dist files
* Revert "Added changed dist files"
This reverts commit dbda25a228.
* Changed function name and added the functionaity to src/utils folder
* Added unit test
* Added unit test to /test/util
18 lines
946 B
JavaScript
18 lines
946 B
JavaScript
var test = require('tape');
|
|
|
|
var red = "data:image/jpeg;base64,/9j/4AAQSkZJRgABAQAAAQABAAD/2wBDAAYEBQYFBAYGBQYHBwYIChAKCgkJChQODwwQFxQYGBcUFhYaHSUfGhsjHBYWICwgIyYnKSopGR8tMC0oMCUoKSj/2wBDAQcHBwoIChMKChMoGhYaKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCj/wAARCAAQABADASIAAhEBAxEB/8QAFQABAQAAAAAAAAAAAAAAAAAAAAf/xAAUEAEAAAAAAAAAAAAAAAAAAAAA/8QAFQEBAQAAAAAAAAAAAAAAAAAABgj/xAAUEQEAAAAAAAAAAAAAAAAAAAAA/9oADAMBAAIRAxEAPwCdABykX//Z";
|
|
|
|
var parseCornerCoordinateInputs = require('../../src/util/ParseInputCoordinates');
|
|
|
|
|
|
test('parseCornerCoordinateInputs works.', function (t) {
|
|
var options = { x: '10%' },
|
|
coord = { src: red, x: { valInp: options.x, type: 'horizontal' } }
|
|
callback = function (options, coord) {
|
|
options.x = parseInt(coord.x.valInp);
|
|
t.equal(options.x, 1, 'parseCornerCoordinateInputs works.');
|
|
t.end();
|
|
};
|
|
parseCornerCoordinateInputs(options, coord, callback);
|
|
});
|