mirror of
https://github.com/Choices-js/Choices.git
synced 2024-05-18 05:26:35 +02:00
Bug fix for assignment of customProperties in the option template, now uses JSON.stringify()
This commit is contained in:
parent
5dbea2825a
commit
ff46b7c8a0
|
@ -4101,7 +4101,7 @@ var templates = {
|
||||||
disabled = _a.disabled;
|
disabled = _a.disabled;
|
||||||
var opt = new Option(label, value, false, active);
|
var opt = new Option(label, value, false, active);
|
||||||
if (customProperties) {
|
if (customProperties) {
|
||||||
opt.dataset.customProperties = "".concat(customProperties);
|
opt.dataset.customProperties = "".concat(JSON.stringify(customProperties));
|
||||||
}
|
}
|
||||||
opt.disabled = !!disabled;
|
opt.disabled = !!disabled;
|
||||||
return opt;
|
return opt;
|
||||||
|
|
2
public/assets/scripts/choices.min.js
vendored
2
public/assets/scripts/choices.min.js
vendored
File diff suppressed because one or more lines are too long
|
@ -321,7 +321,7 @@ const templates = {
|
||||||
const opt = new Option(label, value, false, active);
|
const opt = new Option(label, value, false, active);
|
||||||
|
|
||||||
if (customProperties) {
|
if (customProperties) {
|
||||||
opt.dataset.customProperties = `${customProperties}`;
|
opt.dataset.customProperties = `${JSON.stringify(customProperties)}`;
|
||||||
}
|
}
|
||||||
|
|
||||||
opt.disabled = !!disabled;
|
opt.disabled = !!disabled;
|
||||||
|
|
Loading…
Reference in a new issue