leisure-core 1.0.2 → 1.0.4

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.
Files changed (94) hide show
  1. package/index.js +223 -0
  2. package/le-area/index.js +7 -0
  3. package/le-area/src/main.vue +112 -0
  4. package/le-button/index.js +7 -0
  5. package/le-button/src/main.vue +47 -0
  6. package/le-button-attach/index.js +6 -0
  7. package/le-button-attach/src/main.vue +171 -0
  8. package/le-button-msg/index.js +7 -0
  9. package/le-button-msg/src/main.vue +65 -0
  10. package/le-button-qr/index.js +7 -0
  11. package/le-button-qr/src/main.vue +96 -0
  12. package/le-date-picker/index.js +7 -0
  13. package/le-date-picker/src/main.vue +67 -0
  14. package/le-date-picker-auto/index.js +6 -0
  15. package/le-date-picker-auto/src/main.vue +131 -0
  16. package/le-dialog-container/index.js +7 -0
  17. package/le-dialog-container/src/main.vue +80 -0
  18. package/le-form/index.js +7 -0
  19. package/le-form/src/main.vue +13 -0
  20. package/le-form-item/index.js +7 -0
  21. package/le-form-item/src/main.vue +13 -0
  22. package/le-home/index.js +7 -0
  23. package/le-home/src/LeHeaderMenu.vue +60 -0
  24. package/le-home/src/main.vue +1307 -0
  25. package/le-home/src/sub.vue +82 -0
  26. package/le-image/index.js +7 -0
  27. package/le-image/src/main.vue +53 -0
  28. package/le-input/index.js +7 -0
  29. package/le-input/src/main.vue +15 -0
  30. package/le-input-advanced/index.js +7 -0
  31. package/le-input-advanced/src/main.vue +71 -0
  32. package/le-input-number/index.js +7 -0
  33. package/le-input-number/src/main.vue +15 -0
  34. package/le-input-validate/index.js +6 -0
  35. package/le-input-validate/src/main.vue +469 -0
  36. package/le-libs/js/drag.js +78 -0
  37. package/le-libs/js/event.js +3 -0
  38. package/le-libs/js/hrequest.js +76 -0
  39. package/le-libs/js/hrequestFile.js +151 -0
  40. package/le-libs/js/info.js +7 -0
  41. package/le-libs/js/tokens.js +13 -0
  42. package/le-libs/mixins/main.js +48 -0
  43. package/le-list/index.js +7 -0
  44. package/le-list/src/main.vue +645 -0
  45. package/le-list-form/index.js +7 -0
  46. package/le-list-form/src/main.vue +474 -0
  47. package/le-login/index.js +7 -0
  48. package/le-login/src/ForgotPassword.vue +613 -0
  49. package/le-login/src/main.vue +982 -0
  50. package/le-media/index.js +7 -0
  51. package/le-media/src/main.vue +298 -0
  52. package/le-media-list/index.js +7 -0
  53. package/le-media-list/src/main.vue +178 -0
  54. package/le-media-upload/index.js +7 -0
  55. package/le-media-upload/src/main.vue +329 -0
  56. package/le-menu/index.js +7 -0
  57. package/le-menu/src/main.vue +248 -0
  58. package/le-report/index.js +6 -0
  59. package/le-report/src/main.vue +1747 -0
  60. package/le-report/src/rmixins.js +30 -0
  61. package/le-role/index.js +7 -0
  62. package/le-role/src/main.vue +183 -0
  63. package/le-role/src/sub.vue +79 -0
  64. package/le-role-user/index.js +7 -0
  65. package/le-role-user/src/main.vue +160 -0
  66. package/le-role-user/src/sub.vue +90 -0
  67. package/le-select/index.js +7 -0
  68. package/le-select/src/main.vue +49 -0
  69. package/le-select-multi/index.js +6 -0
  70. package/le-select-multi/src/main.vue +816 -0
  71. package/le-select-option/index.js +7 -0
  72. package/le-select-option/src/main.vue +69 -0
  73. package/le-select-search/index.js +7 -0
  74. package/le-select-search/src/main.vue +46 -0
  75. package/le-span/index.js +7 -0
  76. package/le-span/src/main.vue +29 -0
  77. package/le-table-edit/index.js +6 -0
  78. package/le-table-edit/src/main.vue +689 -0
  79. package/le-theme/common/vars.css +131 -0
  80. package/le-theme/iconfont/iconfont.css +125 -0
  81. package/le-theme/iconfont/iconfont.ttf +0 -0
  82. package/le-theme/iconfont/iconfont.woff +0 -0
  83. package/le-theme/iconfont/iconfont.woff2 +0 -0
  84. package/le-theme/index.js +189 -0
  85. package/le-theme/pages/index.css +15 -0
  86. package/le-upload/index.js +7 -0
  87. package/le-upload/src/main.vue +134 -0
  88. package/le-upload-table/index.js +6 -0
  89. package/le-upload-table/src/main.vue +648 -0
  90. package/le-url/index.js +7 -0
  91. package/le-url/src/main.vue +27 -0
  92. package/le-video/index.js +7 -0
  93. package/le-video/src/main.vue +42 -0
  94. package/package.json +1 -6
@@ -0,0 +1,7 @@
1
+ import LeSelectOption from "./src/main.vue";
2
+
3
+ LeSelectOption.install = function (Vue) {
4
+ Vue.component(LeSelectOption.name, LeSelectOption);
5
+ };
6
+
7
+ export default LeSelectOption;
@@ -0,0 +1,69 @@
1
+ <template>
2
+ <div>
3
+ <el-option
4
+ v-for="(item, index) in options"
5
+ :key="getOptionKey(index)"
6
+ :label="getOptionLabel(item)"
7
+ :value="getOptionValue(item)"
8
+ ></el-option>
9
+ </div>
10
+ </template>
11
+ <script>
12
+ let instanceCounter = 0;
13
+ export default {
14
+ name: "le-select-option",
15
+ props: {
16
+ options: {
17
+ type: Array,
18
+ default() {
19
+ return [];
20
+ },
21
+ },
22
+ value: {
23
+ type: [String, Number],
24
+ default: "",
25
+ },
26
+ label: {
27
+ type: String,
28
+ default: "",
29
+ },
30
+ keyNum: {
31
+ type: [String, Number],
32
+ default: 1,
33
+ },
34
+ },
35
+ data() {
36
+ return {
37
+ instanceId: instanceCounter++,
38
+ };
39
+ },
40
+ mounted() {},
41
+ methods: {
42
+ // handleKv(type, item) {
43
+ // if (this.keyNum == 1) {
44
+ // if (type == "key" || type == "value") {
45
+ // return item[this.value];
46
+ // } else if (type == "label") {
47
+ // return item[this.label];
48
+ // }
49
+ // }
50
+ // if (this.keyNum == 2) {
51
+ // return item[this.value] + "-" + item[this.label];
52
+ // }
53
+ // },
54
+
55
+ getOptionKey(index) {
56
+ // 最简单可靠的方案:使用组件实例ID + 索引
57
+ return `${this.instanceId}_${index}`;
58
+ },
59
+
60
+ getOptionLabel(item) {
61
+ return item[this.label] || "";
62
+ },
63
+
64
+ getOptionValue(item) {
65
+ return item[this.value] || "";
66
+ },
67
+ },
68
+ };
69
+ </script>
@@ -0,0 +1,7 @@
1
+ import LeSelectSearch from "./src/main.vue";
2
+
3
+ LeSelectSearch.install = function (Vue) {
4
+ Vue.component(LeSelectSearch.name, LeSelectSearch);
5
+ };
6
+
7
+ export default LeSelectSearch;
@@ -0,0 +1,46 @@
1
+ <template>
2
+ <le-select
3
+ v-bind="$attrs"
4
+ v-on="$listeners"
5
+ remote
6
+ multiple
7
+ filterable
8
+ reserve-keyword
9
+ placeholder="请输入搜索关键字"
10
+ :remote-method="remoteMethod"
11
+ :loading="loading"
12
+ >
13
+ <slot></slot>
14
+ </le-select>
15
+ </template>
16
+ <script>
17
+ import LeSelect from "../../le-select/index";
18
+ export default {
19
+ name: "le-select-search",
20
+ components: { LeSelect },
21
+ props: {
22
+ remote: {
23
+ type: Boolean,
24
+ default: false,
25
+ },
26
+ },
27
+ inheritAttrs: false,
28
+ data() {
29
+ return {
30
+ loading: false,
31
+ selectValue: "",
32
+ };
33
+ },
34
+ methods: {
35
+ remoteMethod(params) {
36
+ if (params !== "") {
37
+ this.loading = true;
38
+ this.$emit("remoteMethod", params, () => {
39
+ this.loading = false;
40
+ });
41
+ }
42
+ },
43
+ },
44
+ };
45
+ </script>
46
+ <style lang="scss" scoped></style>
@@ -0,0 +1,7 @@
1
+ import LeSpan from "./src/main.vue";
2
+
3
+ LeSpan.install = function (Vue) {
4
+ Vue.component(LeSpan.name, LeSpan);
5
+ };
6
+
7
+ export default LeSpan;
@@ -0,0 +1,29 @@
1
+ <template>
2
+ <span :class="['text-class', customClass]" :style="customStyle">{{
3
+ value
4
+ }}</span>
5
+ </template>
6
+ <script>
7
+ export default {
8
+ name: "le-span",
9
+ props: {
10
+ value: {
11
+ type: [String, Number],
12
+ required: true,
13
+ },
14
+ customClass: {
15
+ type: [String, Array, Object],
16
+ default: "",
17
+ },
18
+ customStyle: {
19
+ type: Object,
20
+ default: () => ({}),
21
+ },
22
+ },
23
+ methods: {},
24
+ };
25
+ </script>
26
+ <style lang="scss" scoped>
27
+ .text-class {
28
+ }
29
+ </style>
@@ -0,0 +1,6 @@
1
+ import LeTableEdit from "./src/main.vue";
2
+
3
+ LeTableEdit.install = function (Vue) {
4
+ Vue.component(LeTableEdit.name, LeTableEdit);
5
+ };
6
+ export default LeTableEdit;