mirror of
https://github.com/lrsjng/h5ai.git
synced 2025-05-23 19:47:04 -04:00
Replace jQuery.qrcode with kjua 0.1.1.
This commit is contained in:
parent
1fc72d8473
commit
8ef9575e51
6 changed files with 16 additions and 11 deletions
|
@ -1,4 +1,4 @@
|
|||
const {win, jq, lo} = require('../globals');
|
||||
const {win, jq, lo, kjua} = require('../globals');
|
||||
const event = require('../core/event');
|
||||
const format = require('../core/format');
|
||||
const resource = require('../core/resource');
|
||||
|
@ -94,13 +94,16 @@ function update(item) {
|
|||
}
|
||||
|
||||
if (settings.qrcode) {
|
||||
$qrcode.empty().qrcode({
|
||||
render: 'canvas',
|
||||
const loc = win.location;
|
||||
$qrcode.empty().append(kjua({
|
||||
render: 'image',
|
||||
size: 200,
|
||||
fill: settings.qrColor,
|
||||
background: null,
|
||||
text: win.location.protocol + '//' + win.location.host + item.absHref
|
||||
});
|
||||
fill: settings.qrFill,
|
||||
back: settings.qrBack,
|
||||
text: loc.protocol + '//' + loc.host + item.absHref,
|
||||
crisp: true,
|
||||
quiet: 1
|
||||
}));
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue