ywana-core8 0.0.418 → 0.0.421
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs +6 -7
- package/dist/index.cjs.map +1 -1
- package/dist/index.modern.js +6 -7
- package/dist/index.modern.js.map +1 -1
- package/dist/index.umd.js +6 -7
- package/dist/index.umd.js.map +1 -1
- package/package.json +1 -1
- package/src/domain/ContentEditor.js +0 -1
- package/src/domain/ContentEditor.test.js +0 -1
- package/src/html/table.js +0 -2
- package/src/html/table.test.js +6 -1
- package/src/html/tokenfield.js +4 -3
- package/src/widgets/upload/UploadDialog.js +2 -1
package/dist/index.cjs
CHANGED
@@ -1908,8 +1908,6 @@ var TokenField = function TokenField(_ref) {
|
|
1908
1908
|
value = _useState[0],
|
1909
1909
|
setValue = _useState[1];
|
1910
1910
|
|
1911
|
-
React.useState(false);
|
1912
|
-
|
1913
1911
|
function remove(index) {
|
1914
1912
|
var next = tokens.slice();
|
1915
1913
|
next.splice(index, 1);
|
@@ -1922,7 +1920,7 @@ var TokenField = function TokenField(_ref) {
|
|
1922
1920
|
}
|
1923
1921
|
|
1924
1922
|
function changeDropDown(fid, value) {
|
1925
|
-
var next = tokens.concat(value);
|
1923
|
+
var next = Array.isArray(tokens) ? tokens.concat(value) : [value];
|
1926
1924
|
if (onChange) onChange(id, next);
|
1927
1925
|
setValue('');
|
1928
1926
|
}
|
@@ -1944,9 +1942,10 @@ var TokenField = function TokenField(_ref) {
|
|
1944
1942
|
}
|
1945
1943
|
}
|
1946
1944
|
|
1945
|
+
var tks = Array.isArray(tokens) ? tokens : [];
|
1947
1946
|
return /*#__PURE__*/React__default["default"].createElement("div", {
|
1948
1947
|
className: "tokenField"
|
1949
|
-
}, /*#__PURE__*/React__default["default"].createElement("label", null, label),
|
1948
|
+
}, /*#__PURE__*/React__default["default"].createElement("label", null, label), tks.map(function (text, index) {
|
1950
1949
|
return /*#__PURE__*/React__default["default"].createElement(Token, {
|
1951
1950
|
text: text,
|
1952
1951
|
onDelete: function onDelete() {
|
@@ -3466,7 +3465,8 @@ var UploadDialog = function UploadDialog(_ref) {
|
|
3466
3465
|
accept = _ref.accept,
|
3467
3466
|
onSuccess = _ref.onSuccess,
|
3468
3467
|
onComplete = _ref.onComplete,
|
3469
|
-
onClose = _ref.onClose
|
3468
|
+
onClose = _ref.onClose,
|
3469
|
+
children = _ref.children;
|
3470
3470
|
var site = React.useContext(SiteContext);
|
3471
3471
|
|
3472
3472
|
function success(file, message) {
|
@@ -3504,7 +3504,7 @@ var UploadDialog = function UploadDialog(_ref) {
|
|
3504
3504
|
target: target,
|
3505
3505
|
onSuccess: success,
|
3506
3506
|
onComplete: complete
|
3507
|
-
}));
|
3507
|
+
}), children);
|
3508
3508
|
};
|
3509
3509
|
|
3510
3510
|
/**
|
@@ -4103,7 +4103,6 @@ var StringEditor = function StringEditor(_ref6) {
|
|
4103
4103
|
Editor = field.Editor;
|
4104
4104
|
|
4105
4105
|
function change(id, value) {
|
4106
|
-
console.log(id, value);
|
4107
4106
|
if (onChange) onChange(id, value);
|
4108
4107
|
}
|
4109
4108
|
|