element-ui+2.13.2.patch 3.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869
  1. diff --git a/node_modules/element-ui/lib/cascader-panel.js b/node_modules/element-ui/lib/cascader-panel.js
  2. index 0f3f827..aba337b 100644
  3. --- a/node_modules/element-ui/lib/cascader-panel.js
  4. +++ b/node_modules/element-ui/lib/cascader-panel.js
  5. @@ -1050,7 +1050,7 @@ var store_Store = function () {
  6. };
  7. Store.prototype.getNodeByValue = function getNodeByValue(value) {
  8. - if (value) {
  9. + if (value || value === 0) {
  10. var nodes = this.getFlattedNodes(false, !this.config.lazy).filter(function (node) {
  11. return Object(util_["valueEquals"])(node.path, value) || node.value === value;
  12. });
  13. diff --git a/node_modules/element-ui/lib/cascader.js b/node_modules/element-ui/lib/cascader.js
  14. index ee4bc3d..d39b5a4 100644
  15. --- a/node_modules/element-ui/lib/cascader.js
  16. +++ b/node_modules/element-ui/lib/cascader.js
  17. @@ -911,7 +911,7 @@ var InputSizeMap = {
  18. data: function data() {
  19. return {
  20. dropDownVisible: false,
  21. - checkedValue: this.value || null,
  22. + checkedValue: this.value,
  23. inputHover: false,
  24. inputValue: null,
  25. presentText: null,
  26. @@ -1039,7 +1039,7 @@ var InputSizeMap = {
  27. this.inputInitialHeight = input.$el.offsetHeight || InputSizeMap[this.realSize] || 40;
  28. }
  29. - if (!Object(util_["isEmpty"])(this.value)) {
  30. + if (this.value === 0 || !Object(util_["isEmpty"])(this.value)) {
  31. this.computePresentContent();
  32. }
  33. @@ -1189,7 +1189,7 @@ var InputSizeMap = {
  34. var checkedValue = this.checkedValue,
  35. config = this.config;
  36. - if (!Object(util_["isEmpty"])(checkedValue)) {
  37. + if (checkedValue === 0 || !Object(util_["isEmpty"])(checkedValue)) {
  38. var node = this.panel.getNodeByValue(checkedValue);
  39. if (node && (config.checkStrictly || node.isLeaf)) {
  40. this.presentText = node.getText(this.showAllLevels, this.separator);
  41. diff --git a/node_modules/element-ui/lib/utils/util.js b/node_modules/element-ui/lib/utils/util.js
  42. index 1ced2ab..bfa9001 100644
  43. --- a/node_modules/element-ui/lib/utils/util.js
  44. +++ b/node_modules/element-ui/lib/utils/util.js
  45. @@ -215,7 +215,7 @@ var isEmpty = exports.isEmpty = function isEmpty(val) {
  46. if (typeof val === 'boolean') return false;
  47. - if (typeof val === 'number') return !val;
  48. + if (typeof val === 'number') return false;
  49. if (val instanceof Error) return val.message === '';
  50. diff --git a/node_modules/element-ui/packages/.DS_Store b/node_modules/element-ui/packages/.DS_Store
  51. deleted file mode 100644
  52. index 1c1f7f4..0000000
  53. Binary files a/node_modules/element-ui/packages/.DS_Store and /dev/null differ
  54. diff --git a/node_modules/element-ui/packages/theme-chalk/src/.DS_Store b/node_modules/element-ui/packages/theme-chalk/src/.DS_Store
  55. deleted file mode 100644
  56. index 94b4cf9..0000000
  57. Binary files a/node_modules/element-ui/packages/theme-chalk/src/.DS_Store and /dev/null differ
  58. diff --git a/node_modules/element-ui/packages/theme-chalk/src/fonts/.DS_Store b/node_modules/element-ui/packages/theme-chalk/src/fonts/.DS_Store
  59. deleted file mode 100644
  60. index 5008ddf..0000000
  61. Binary files a/node_modules/element-ui/packages/theme-chalk/src/fonts/.DS_Store and /dev/null differ