Skip to content

Commit

Permalink
I did it. Close #14
Browse files Browse the repository at this point in the history
  • Loading branch information
lelinhtinh committed Feb 3, 2020
1 parent 1adc0a1 commit bdba285
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 5 deletions.
10 changes: 7 additions & 3 deletions dist/jquery.watermark.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* Project: jQuery plugin Watermark
* Description: Add watermark on images use HTML5 and Javascript.
* Author: Zzbaivong (devs.forumvi.com)
* Version: 0.2
* Version: 1.0.1
* License: MIT
*/

Expand All @@ -28,7 +28,7 @@
textColor: 'white',
textBg: 'rgba(0, 0, 0, 0.4)',

gravity: 'se', // nw | n | ne | w | e | sw | s | se
gravity: 'se', // nw | n | ne | w | e | sw | s | se | c
opacity: 0.7,
margin: 0,
fullOverlay: false,
Expand Down Expand Up @@ -205,7 +205,7 @@
gTop;

switch (
set.gravity // nw | n | ne | w | e | sw | s | se
set.gravity // nw | n | ne | w | e | sw | s | se | c
) {
case 'nw': // Tây bắc
gLeft = pos;
Expand Down Expand Up @@ -235,6 +235,10 @@
gLeft = w / 2 - wmW / 2;
gTop = h - wmH - pos;
break;
case 'c': // Trung tâm
gLeft = w / 2 - wmW / 2;
gTop = (h - wmH) / 2;
break;
default:
// Đông Nam
gLeft = w - wmW - pos;
Expand Down
4 changes: 2 additions & 2 deletions dist/jquery.watermark.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit bdba285

Please sign in to comment.