Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Restore original proportions tool and bug fixes #274

Merged
merged 44 commits into from
Jun 27, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
44 commits
Select commit Hold shift + click to select a range
f68eae1
sdf
sashadev-sky Jun 15, 2019
aedac37
implement restore function
sashadev-sky May 29, 2019
5fd2484
Fix coordinates bug
sashadev-sky May 29, 2019
5bae884
Update README demos
sashadev-sky May 29, 2019
db52b50
create ImageUtil file
sashadev-sky May 29, 2019
77ba084
sfd
sashadev-sky May 30, 2019
6357093
cleanup
sashadev-sky May 30, 2019
450fd40
Cleanup 2
sashadev-sky May 30, 2019
a3799ae
Cleanup 3
sashadev-sky May 30, 2019
d9d02b8
test cleanup
sashadev-sky May 30, 2019
c7755dd
sdgh
sashadev-sky Jun 15, 2019
16241dd
Implement svg
sashadev-sky Jun 18, 2019
5cfd9b7
Accessibility
sashadev-sky Jun 18, 2019
fc7cae1
add opacity full
sashadev-sky Jun 18, 2019
0d1df94
Optimize svgs
sashadev-sky Jun 18, 2019
b045084
refactor
sashadev-sky Jun 18, 2019
ecca5ce
Stop creating new toolbar instances
sashadev-sky Jun 18, 2019
065bfd1
refactor
sashadev-sky Jun 18, 2019
4537d90
Refactor pt.2
sashadev-sky Jun 18, 2019
f2224fe
Refactoring 3
sashadev-sky Jun 18, 2019
a976d45
Refactor 3
sashadev-sky Jun 18, 2019
c166775
commit
sashadev-sky Jun 18, 2019
ac0418f
readme
sashadev-sky Jun 18, 2019
9a4882c
Add xlink for safari 7 support
sashadev-sky Jun 19, 2019
de6b768
correct polyfill usage confirmed
sashadev-sky Jun 19, 2019
7fa779e
update restore icon to filled icon
sashadev-sky Jun 19, 2019
b1f3f2c
Icon normalization
sashadev-sky Jun 19, 2019
745665d
Readme
sashadev-sky Jun 19, 2019
6f68083
remove useless css
sashadev-sky Jun 19, 2019
0a6fbfa
Toolbar documentation updates
sashadev-sky Jun 19, 2019
69cf37c
doc updates
sashadev-sky Jun 19, 2019
981ff83
docs
sashadev-sky Jun 19, 2019
aa74c0f
refactor
sashadev-sky Jun 20, 2019
f27aa9e
README icon ref
sashadev-sky Jun 21, 2019
3214fe8
version bump
sashadev-sky Jun 21, 2019
cefad7d
README format
sashadev-sky Jun 25, 2019
f09f701
update polyfill comment
sashadev-sky Jun 25, 2019
c4199f5
Update Gruntfile compile command
sashadev-sky Jun 25, 2019
b491fe4
add svgo minifier
sashadev-sky Jun 25, 2019
d947493
update wikis
sashadev-sky Jun 26, 2019
763ad36
remove commented lines
sashadev-sky Jun 26, 2019
be4254c
Remove trailing commas
sashadev-sky Jun 26, 2019
faab4db
undo version bump
sashadev-sky Jun 27, 2019
0e8fb6a
Fix capitalization
sashadev-sky Jun 27, 2019
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
214 changes: 131 additions & 83 deletions Gruntfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,99 +3,145 @@ module.exports = function(grunt) {
require('matchdep').filterDev('grunt-*').forEach(grunt.loadNpmTasks);

grunt.initConfig({
pkg: grunt.file.readJSON('package.json'),

jshint: {
options: {
node: true,
browser: true,
esnext: true,
bitwise: true,
curly: true,
eqeqeq: true,
immed: true,
indent: 4,
latedef: true,
newcap: true,
noarg: true,
regexp: true,
undef: true,
unused: 'strict',
trailing: true,
smarttabs: true,
globals: {
L: false,
$: false,
LeafletToolbar: false,
warpWebGl: false,
EXIF: false,
alert: false,

// Mocha

describe: false,
it: false,
before: false,
after: false,
beforeEach: false,
afterEach: false,
chai: false,
expect: false,
sinon: false
}
},
source: {
src: [ 'src/**/*.js', 'package.json' ]
},
grunt: {
src: [ 'Gruntfile.js' ]
}
pkg: grunt.file.readJSON("package.json"),

jshint: {
options: {
node: true,
browser: true,
esnext: true,
bitwise: true,
curly: true,
eqeqeq: true,
immed: true,
indent: 4,
latedef: true,
newcap: true,
noarg: true,
regexp: true,
undef: true,
unused: "strict",
trailing: true,
smarttabs: true,
globals: {
L: false,
$: false,
LeafletToolbar: false,
warpWebGl: false,
EXIF: false,
alert: false,

// Mocha

describe: false,
it: false,
before: false,
after: false,
beforeEach: false,
afterEach: false,
chai: false,
expect: false,
sinon: false
}
},
source: {
src: ["src/**/*.js", "package.json"]
},
grunt: {
src: ["Gruntfile.js"]
}
},

karma: {
development: {
configFile: 'test/karma.conf.js',
},
test: {
configFile: 'test/karma.conf.js',
karma: {
development: {
configFile: "test/karma.conf.js"
},
test: {
configFile: "test/karma.conf.js"
}
},

// Minify SVGs from svg directory, output to svg-min
svgmin: {
dist: {
files: [
{
attrs: "fill",
expand: true,
cwd: "assets/icons/svg",
src: ["*.svg"],
dest: "assets/icons/svg-min/",
ext: ".svg"
}
]
},
options: {
plugins: [
{ removeViewBox: false },
{ removeEmptyAttrs: false },
{ removeTitle: true } // addtitle will add it back in later
]
}
},

watch: {
options : {
livereload: true
svg_sprite: {
options: {
// Task-specific options go here.
},
dist: {
expand: true,
cwd: "assets/icons/svg-min/",
src: ["*.svg"],
dest: "assets/icons/",
options: {
log: "info",
shape: {
dimension: {
maxWidth: 18,
maxHeight: 18
}
},
source: {
files: [
'src/**/*.js',
'test/**/*.js',
'Gruntfile.js'
],
tasks: [ 'build:js' ]
mode: {
symbol: {
sprite: "sprite.symbol.svg",
example: true
}
}
}
}
},

watch: {
options: {
livereload: true
},
source: {
files: ["src/**/*.js", "test/**/*.js", "Gruntfile.js"],
tasks: ["build:js"]
}
},

concat: {
dist: {
src: [
'src/util/*.js',
'src/DistortableImageOverlay.js',
'src/DistortableCollection.js',
'src/edit/getEXIFdata.js',
'src/edit/EditHandle.js',
'src/edit/LockHandle.js',
'src/edit/DistortHandle.js',
'src/edit/RotateScaleHandle.js',
'src/edit/RotateHandle.js',
'src/edit/ScaleHandle.js',
'src/edit/DistortableImage.EditToolbar.js',
'src/edit/DistortableImage.Edit.js',
'src/edit/tools/DistortableImage.Keymapper.js',
'src/edit/BoxSelectHandle.js'
],
dest: 'dist/leaflet.distortableimage.js',
}
concat: {
dist: {
src: [
"src/util/*.js",
"src/DistortableImageOverlay.js",
"src/DistortableCollection.js",
"src/edit/getEXIFdata.js",
"src/edit/EditHandle.js",
"src/edit/LockHandle.js",
"src/edit/DistortHandle.js",
"src/edit/RotateScaleHandle.js",
"src/edit/RotateHandle.js",
"src/edit/ScaleHandle.js",
"src/edit/DistortableImage.EditToolbar.js",
"src/edit/DistortableImage.Edit.js",
"src/edit/tools/DistortableImage.Keymapper.js",
"src/edit/BoxSelectHandle.js"
],
dest: "dist/leaflet.distortableimage.js"
}
}
});

/* Run tests once. */
Expand All @@ -107,6 +153,8 @@ module.exports = function(grunt) {
grunt.registerTask('build', [
'jshint',
'karma:development:start',
'svgmin',
'svg_sprite',
'coverage',
'concat:dist'
]);
Expand Down
Loading