@cgboiler/biz-mobile 1.18.5-beta → 1.18.5

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 (39) hide show
  1. package/es/index.d.ts +1 -1
  2. package/es/index.js +1 -1
  3. package/es/md-preview/index.less +101 -101
  4. package/es/org-picker/OrgPicker.d.ts +3 -3
  5. package/es/org-picker/OrgPicker.js +19 -5
  6. package/es/org-picker/_atomic.css +1 -0
  7. package/es/org-picker/index.less +181 -181
  8. package/es/org-picker/types.d.ts +2 -2
  9. package/es/org-picker/useApi.d.ts +7 -7
  10. package/es/org-picker/useApi.js +16 -9
  11. package/es/org-picker/useSearch.d.ts +2 -2
  12. package/es/org-picker/useSearch.js +32 -21
  13. package/es/project-select/index.less +45 -45
  14. package/es/rich-text-editor/RichTextEditor.js +6 -61
  15. package/es/rich-text-editor/_atomic.css +0 -2
  16. package/es/rich-text-editor/index.css +0 -1
  17. package/es/rich-text-editor/index.less +0 -191
  18. package/es/vue-sfc-shim.d.ts +8 -8
  19. package/es/vue-tsx-shim.d.ts +24 -24
  20. package/lib/index.d.ts +1 -1
  21. package/lib/index.js +1 -1
  22. package/lib/md-preview/index.less +101 -101
  23. package/lib/org-picker/OrgPicker.d.ts +3 -3
  24. package/lib/org-picker/OrgPicker.js +19 -5
  25. package/lib/org-picker/_atomic.css +1 -0
  26. package/lib/org-picker/index.less +181 -181
  27. package/lib/org-picker/types.d.ts +2 -2
  28. package/lib/org-picker/useApi.d.ts +7 -7
  29. package/lib/org-picker/useApi.js +15 -8
  30. package/lib/org-picker/useSearch.d.ts +2 -2
  31. package/lib/org-picker/useSearch.js +31 -20
  32. package/lib/project-select/index.less +45 -45
  33. package/lib/rich-text-editor/RichTextEditor.js +5 -70
  34. package/lib/rich-text-editor/_atomic.css +0 -2
  35. package/lib/rich-text-editor/index.css +0 -1
  36. package/lib/rich-text-editor/index.less +0 -191
  37. package/lib/vue-sfc-shim.d.ts +8 -8
  38. package/lib/vue-tsx-shim.d.ts +24 -24
  39. package/package.json +68 -68
package/lib/index.js CHANGED
@@ -45,7 +45,7 @@ __reExport(stdin_exports, require("./md-preview"), module.exports);
45
45
  __reExport(stdin_exports, require("./org-picker"), module.exports);
46
46
  __reExport(stdin_exports, require("./project-select"), module.exports);
47
47
  __reExport(stdin_exports, require("./rich-text-editor"), module.exports);
48
- const version = "1.17.15";
48
+ const version = "1.18.4";
49
49
  function install(app) {
50
50
  const components = [
51
51
  import_md_preview.default,
@@ -1,101 +1,101 @@
1
- .katex-block {
2
- display: block;
3
- margin: 1em 0;
4
- text-align: center;
5
- overflow-x: auto;
6
- overflow-y: hidden;
7
- }
8
-
9
- .cgx-markdown-preview {
10
-
11
- /* 差异对比样式 */
12
- .diff-container {
13
- border: 1px solid #ebeef5;
14
- border-radius: 4px;
15
- overflow: auto;
16
- }
17
-
18
- .diff-equal {
19
- color: #606266;
20
- }
21
-
22
- .diff-delete {
23
- background-color: #ffeef0;
24
- color: #f56c6c;
25
- text-decoration: line-through;
26
- }
27
-
28
- .diff-insert {
29
- background-color: #e6ffec;
30
- color: #67c23a;
31
- }
32
-
33
- .diff-unified-view pre {
34
- margin: 0;
35
- padding: 8px;
36
- white-space: pre-wrap;
37
- word-break: break-word;
38
- }
39
- }
40
-
41
- .cgx-markdown-preview {
42
- line-height: 1.6;
43
- font-size: var(--font-base, 16px);
44
- ol {
45
- list-style: auto;
46
- }
47
-
48
- ul {
49
- list-style: disc;
50
- }
51
-
52
- ol,
53
- ul {
54
- padding-left: 1.5em;
55
- margin: 0 0 12px 0;
56
- }
57
-
58
- li::marker {
59
- text-align: start !important;
60
- }
61
-
62
- h1 {
63
- font-size: 2em;
64
- font-weight: bold;
65
- margin: 16px 0;
66
- }
67
-
68
- h2 {
69
- font-size: 1.5em;
70
- font-weight: bold;
71
- margin: 14px 0;
72
- }
73
-
74
- p {
75
- margin: 12px 0;
76
- }
77
-
78
- blockquote {
79
- margin: 0;
80
- padding-left: 1em;
81
- border-left: 4px solid #ddd;
82
- color: #666;
83
- }
84
-
85
- table {
86
- border-collapse: collapse;
87
- width: 100%;
88
- margin-bottom: 16px;
89
- }
90
-
91
- th,
92
- td {
93
- border: 1px solid #ddd;
94
- padding: 8px;
95
- text-align: left;
96
- }
97
-
98
- th {
99
- background-color: #f6f8fa;
100
- }
101
- }
1
+ .katex-block {
2
+ display: block;
3
+ margin: 1em 0;
4
+ text-align: center;
5
+ overflow-x: auto;
6
+ overflow-y: hidden;
7
+ }
8
+
9
+ .cgx-markdown-preview {
10
+
11
+ /* 差异对比样式 */
12
+ .diff-container {
13
+ border: 1px solid #ebeef5;
14
+ border-radius: 4px;
15
+ overflow: auto;
16
+ }
17
+
18
+ .diff-equal {
19
+ color: #606266;
20
+ }
21
+
22
+ .diff-delete {
23
+ background-color: #ffeef0;
24
+ color: #f56c6c;
25
+ text-decoration: line-through;
26
+ }
27
+
28
+ .diff-insert {
29
+ background-color: #e6ffec;
30
+ color: #67c23a;
31
+ }
32
+
33
+ .diff-unified-view pre {
34
+ margin: 0;
35
+ padding: 8px;
36
+ white-space: pre-wrap;
37
+ word-break: break-word;
38
+ }
39
+ }
40
+
41
+ .cgx-markdown-preview {
42
+ line-height: 1.6;
43
+ font-size: var(--font-base, 16px);
44
+ ol {
45
+ list-style: auto;
46
+ }
47
+
48
+ ul {
49
+ list-style: disc;
50
+ }
51
+
52
+ ol,
53
+ ul {
54
+ padding-left: 1.5em;
55
+ margin: 0 0 12px 0;
56
+ }
57
+
58
+ li::marker {
59
+ text-align: start !important;
60
+ }
61
+
62
+ h1 {
63
+ font-size: 2em;
64
+ font-weight: bold;
65
+ margin: 16px 0;
66
+ }
67
+
68
+ h2 {
69
+ font-size: 1.5em;
70
+ font-weight: bold;
71
+ margin: 14px 0;
72
+ }
73
+
74
+ p {
75
+ margin: 12px 0;
76
+ }
77
+
78
+ blockquote {
79
+ margin: 0;
80
+ padding-left: 1em;
81
+ border-left: 4px solid #ddd;
82
+ color: #666;
83
+ }
84
+
85
+ table {
86
+ border-collapse: collapse;
87
+ width: 100%;
88
+ margin-bottom: 16px;
89
+ }
90
+
91
+ th,
92
+ td {
93
+ border: 1px solid #ddd;
94
+ padding: 8px;
95
+ text-align: left;
96
+ }
97
+
98
+ th {
99
+ background-color: #f6f8fa;
100
+ }
101
+ }
@@ -1,7 +1,7 @@
1
1
  import './index.less';
2
2
  declare const _default: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
3
3
  modelValue: {
4
- type: import("vue").PropType<(string | number)[] | null>;
4
+ type: import("vue").PropType<(string)[] | null>;
5
5
  default: () => null;
6
6
  };
7
7
  show: {
@@ -24,7 +24,7 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
24
24
  };
25
25
  }>, () => import("vue/jsx-runtime").JSX.Element, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("update:show" | "update:modelValue")[], "update:show" | "update:modelValue", import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
26
26
  modelValue: {
27
- type: import("vue").PropType<(string | number)[] | null>;
27
+ type: import("vue").PropType<(string)[] | null>;
28
28
  default: () => null;
29
29
  };
30
30
  show: {
@@ -49,7 +49,7 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
49
49
  "onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
50
50
  "onUpdate:show"?: ((...args: any[]) => any) | undefined;
51
51
  }>, {
52
- modelValue: (string | number)[] | null;
52
+ modelValue: string[] | null;
53
53
  show: boolean;
54
54
  multiple: boolean;
55
55
  autoFocus: boolean;
@@ -56,6 +56,7 @@ var stdin_default = (0, import_vue2.defineComponent)({
56
56
  } = api;
57
57
  getOrgList();
58
58
  const activeTab = (0, import_vue2.ref)("txl");
59
+ const isSearchFocus = (0, import_vue2.ref)(false);
59
60
  const {
60
61
  keyword,
61
62
  searchRef,
@@ -64,7 +65,11 @@ var stdin_default = (0, import_vue2.defineComponent)({
64
65
  handleDeleteHistorySelect,
65
66
  highlightText,
66
67
  renderSearchResult
67
- } = (0, import_useSearch.useSearch)(props, api);
68
+ } = (0, import_useSearch.useSearch)({
69
+ props,
70
+ api,
71
+ isSearchFocus
72
+ });
68
73
  const selectedItems = (0, import_vue2.ref)([]);
69
74
  const sortOrgList = (0, import_vue2.computed)(() => {
70
75
  const departments = orgList.value.filter((item) => item.type === "dept");
@@ -110,7 +115,7 @@ var stdin_default = (0, import_vue2.defineComponent)({
110
115
  }
111
116
  };
112
117
  const handleHistorySelect = (item) => {
113
- selectedItems.value = item.selectedUsers;
118
+ selectedItems.value = item.selectedUsers.map((user) => getUserInfoById(user.id));
114
119
  };
115
120
  const handleConfirm = () => {
116
121
  emit("update:show", false);
@@ -133,6 +138,12 @@ var stdin_default = (0, import_vue2.defineComponent)({
133
138
  "modelValue": keyword.value,
134
139
  "onUpdate:modelValue": ($event) => keyword.value = $event,
135
140
  "placeholder": "\u641C\u7D22\u4EBA\u5458",
141
+ "onFocus": () => {
142
+ isSearchFocus.value = true;
143
+ },
144
+ "onBlur": () => {
145
+ isSearchFocus.value = false;
146
+ },
136
147
  "class": "search-bar"
137
148
  }, null), (0, import_vue.createVNode)("div", {
138
149
  "class": "org-selected-items"
@@ -149,7 +160,7 @@ var stdin_default = (0, import_vue2.defineComponent)({
149
160
  "class": "color-[#aaa] text-[14px] text-center w-full leading-[38px]"
150
161
  }, [(0, import_vue.createTextVNode)("\u672A\u9009\u62E9\u4EBA\u5458")])]), (0, import_vue.createVNode)("div", {
151
162
  "class": "flex-1 flex flex-col overflow-hidden relative"
152
- }, [(0, import_vue.createVNode)(import_vant.Tabs, {
163
+ }, [props.multiple ? (0, import_vue.createVNode)(import_vant.Tabs, {
153
164
  "active": activeTab.value,
154
165
  "onUpdate:active": ($event) => activeTab.value = $event
155
166
  }, {
@@ -160,7 +171,7 @@ var stdin_default = (0, import_vue2.defineComponent)({
160
171
  "title": "\u6700\u8FD1\u9009\u62E9",
161
172
  "name": "zjxz"
162
173
  }, null)]
163
- }), (0, import_vue.createVNode)("div", {
174
+ }) : "", (0, import_vue.createVNode)("div", {
164
175
  "class": "org-content-wrap"
165
176
  }, [activeTab.value === "zjxz" ? (0, import_vue.createVNode)("div", {
166
177
  "class": "recent-list-wrap flex-1 overflow-auto px-[16px] py-[8px]"
@@ -172,7 +183,10 @@ var stdin_default = (0, import_vue2.defineComponent)({
172
183
  "class": "py-8px border-b border-[#eee] flex items-center"
173
184
  }, [(0, import_vue.createVNode)("span", {
174
185
  "class": "flex-1"
175
- }, [historyItem.selectedUsers.map((user) => highlightText(getUserInfoById(user.id), keyword.value)).reduce((prev, curr) => [prev, "\uFF0C", curr])]), (0, import_vue.createVNode)("span", {
186
+ }, [historyItem.selectedUsers.map((user) => {
187
+ var _a;
188
+ return highlightText((_a = getUserInfoById(user.id)) == null ? void 0 : _a.name, keyword.value);
189
+ }).reduce((prev, curr) => [prev, "\uFF0C", curr])]), (0, import_vue.createVNode)("span", {
176
190
  "class": "p-4px pl-2",
177
191
  "onClick": (e) => {
178
192
  e.stopPropagation();
@@ -37,6 +37,7 @@
37
37
  .cgx-atm .right-0{right:0rem;}
38
38
  .cgx-atm .top-0{top:0rem;}
39
39
  .cgx-atm .z-1{z-index:1;}
40
+ .cgx-atm .h-\[300px\]{height:300px;}
40
41
  .cgx-atm .flex-1{flex:1 1 0%;}
41
42
  .cgx-atm .overflow-auto{overflow:auto;}
42
43
  .cgx-atm .border-b{border-bottom-width:1px;border-bottom-style:solid;}
@@ -1,181 +1,181 @@
1
- :root:root {
2
- --van-action-sheet-max-height: 100%;
3
- }
4
- .org-list {
5
- height: 85vh;
6
- display: flex;
7
- flex-direction: column;
8
-
9
- .highlight {
10
- color: var(--van-primary-color);
11
- font-weight: bold;
12
- }
13
-
14
- .breadcrumb-nav {
15
- margin-bottom: 4px;
16
- padding: 2px 16px;
17
- border-radius: 4px;
18
- font-size: 12px;
19
-
20
- .dept-name {
21
- &.current-dept {
22
- color: #969799; /* 提示文字颜色 */
23
- }
24
- }
25
-
26
- .separator {
27
- color: #969799;
28
- margin: 0 4px;
29
- }
30
- }
31
-
32
- .search-bar {
33
- position: sticky;
34
- top: 0;
35
- z-index: 1;
36
- }
37
-
38
- .org-selected-items {
39
- display: flex;
40
- flex-wrap: nowrap;
41
- padding: 12px 16px;
42
- gap: 12px;
43
- background-color: #fff;
44
- overflow-x: auto;
45
- height: 68px;
46
- border-bottom: 1px solid #eee;
47
-
48
- .selected-tag {
49
- flex-shrink: 0;
50
- background: none;
51
- border: none;
52
- padding: 0;
53
- margin: 0;
54
- position: relative;
55
- .close-icon {
56
- position: absolute;
57
- top: 0;
58
- right: 0;
59
- z-index: 1;
60
- background-color: #fff;
61
- border-radius: 50%;
62
- border: 1px solid #eee;
63
- width: 10px;
64
- height: 10px;
65
- display: flex;
66
- align-items: center;
67
- justify-content: center;
68
- font-size: 6px;
69
- color: #969799;
70
- }
71
-
72
- .tag-avatar {
73
- width: 40px;
74
- height: 40px;
75
- img {
76
- border-radius: 4px;
77
- border: 1px solid #eee;
78
- object-fit: contain;
79
- }
80
- }
81
- }
82
- }
83
-
84
- .bottom-section {
85
- border-top: 1px solid #eee;
86
- background-color: #fff;
87
- }
88
-
89
- .van-list {
90
- flex: 1;
91
- overflow-y: auto;
92
- padding: 0 16px;
93
- }
94
-
95
- .org-content-wrap {
96
- flex: 1;
97
- display: flex;
98
- flex-direction: column;
99
- overflow: hidden;
100
- position: relative;
101
- padding-top: 4px;
102
- }
103
-
104
- .feed-list-wrap {
105
- flex: 1;
106
- display: flex;
107
- overflow: hidden;
108
- position: relative;
109
- justify-content: center;
110
- }
111
- .search-result-list {
112
- position: absolute;
113
- top: 0; /* Adjust based on search bar and breadcrumb height */
114
- left: 0;
115
- right: 0;
116
- bottom: 0; /* Adjust based on bottom section height if multiple is true */
117
- z-index: 1;
118
- background-color: #fff; /* Ensure background is white */
119
- overflow-y: auto;
120
- padding: 0 16px;
121
- }
122
-
123
- .org-item {
124
- padding: 12px 0;
125
- border-bottom: 1px solid #eee;
126
- cursor: pointer;
127
- display: flex;
128
- align-items: center;
129
- gap: 12px;
130
-
131
- .org-item-select-icon {
132
- display: none;
133
- padding-left: 4px;
134
- }
135
- &.selected {
136
- color: var(--van-primary-color);
137
- .org-item-select-icon {
138
- display: inline;
139
- }
140
- }
141
-
142
- .org-avatar {
143
- flex-shrink: 0;
144
- width: 40px;
145
- height: 40px;
146
- display: flex;
147
- align-items: center;
148
- justify-content: center;
149
- img {
150
- border-radius: 4px;
151
- border: 1px solid #eee;
152
- object-fit: contain;
153
- }
154
- }
155
-
156
- .org-name {
157
- font-size: 14px;
158
- flex: 1;
159
- }
160
-
161
- &:last-child {
162
- border-bottom: none;
163
- }
164
- }
165
-
166
- .action-buttons {
167
- padding: 16px;
168
- display: flex;
169
- justify-content: center;
170
-
171
- .confirm-button {
172
- background-color: var(--van-primary-color);
173
- color: white;
174
- padding: 10px 0;
175
- border-radius: 4px;
176
- text-align: center;
177
- width: 100%;
178
- font-size: 14px;
179
- }
180
- }
181
- }
1
+ :root:root {
2
+ --van-action-sheet-max-height: 100%;
3
+ }
4
+ .org-list {
5
+ height: 85vh;
6
+ display: flex;
7
+ flex-direction: column;
8
+
9
+ .highlight {
10
+ color: var(--van-primary-color);
11
+ font-weight: bold;
12
+ }
13
+
14
+ .breadcrumb-nav {
15
+ margin-bottom: 4px;
16
+ padding: 2px 16px;
17
+ border-radius: 4px;
18
+ font-size: 12px;
19
+
20
+ .dept-name {
21
+ &.current-dept {
22
+ color: #969799; /* 提示文字颜色 */
23
+ }
24
+ }
25
+
26
+ .separator {
27
+ color: #969799;
28
+ margin: 0 4px;
29
+ }
30
+ }
31
+
32
+ .search-bar {
33
+ position: sticky;
34
+ top: 0;
35
+ z-index: 1;
36
+ }
37
+
38
+ .org-selected-items {
39
+ display: flex;
40
+ flex-wrap: nowrap;
41
+ padding: 12px 16px;
42
+ gap: 12px;
43
+ background-color: #fff;
44
+ overflow-x: auto;
45
+ height: 68px;
46
+ border-bottom: 1px solid #eee;
47
+
48
+ .selected-tag {
49
+ flex-shrink: 0;
50
+ background: none;
51
+ border: none;
52
+ padding: 0;
53
+ margin: 0;
54
+ position: relative;
55
+ .close-icon {
56
+ position: absolute;
57
+ top: 0;
58
+ right: 0;
59
+ z-index: 1;
60
+ background-color: #fff;
61
+ border-radius: 50%;
62
+ border: 1px solid #eee;
63
+ width: 10px;
64
+ height: 10px;
65
+ display: flex;
66
+ align-items: center;
67
+ justify-content: center;
68
+ font-size: 6px;
69
+ color: #969799;
70
+ }
71
+
72
+ .tag-avatar {
73
+ width: 40px;
74
+ height: 40px;
75
+ img {
76
+ border-radius: 4px;
77
+ border: 1px solid #eee;
78
+ object-fit: contain;
79
+ }
80
+ }
81
+ }
82
+ }
83
+
84
+ .bottom-section {
85
+ border-top: 1px solid #eee;
86
+ background-color: #fff;
87
+ }
88
+
89
+ .van-list {
90
+ flex: 1;
91
+ overflow-y: auto;
92
+ padding: 0 16px;
93
+ }
94
+
95
+ .org-content-wrap {
96
+ flex: 1;
97
+ display: flex;
98
+ flex-direction: column;
99
+ overflow: hidden;
100
+ position: relative;
101
+ padding-top: 4px;
102
+ }
103
+
104
+ .feed-list-wrap {
105
+ flex: 1;
106
+ display: flex;
107
+ overflow: hidden;
108
+ position: relative;
109
+ justify-content: center;
110
+ }
111
+ .search-result-list {
112
+ position: absolute;
113
+ top: 0; /* Adjust based on search bar and breadcrumb height */
114
+ left: 0;
115
+ right: 0;
116
+ bottom: 0; /* Adjust based on bottom section height if multiple is true */
117
+ z-index: 1;
118
+ background-color: #fff; /* Ensure background is white */
119
+ overflow-y: auto;
120
+ padding: 0 16px;
121
+ }
122
+
123
+ .org-item {
124
+ padding: 12px 0;
125
+ border-bottom: 1px solid #eee;
126
+ cursor: pointer;
127
+ display: flex;
128
+ align-items: center;
129
+ gap: 12px;
130
+
131
+ .org-item-select-icon {
132
+ display: none;
133
+ padding-left: 4px;
134
+ }
135
+ &.selected {
136
+ color: var(--van-primary-color);
137
+ .org-item-select-icon {
138
+ display: inline;
139
+ }
140
+ }
141
+
142
+ .org-avatar {
143
+ flex-shrink: 0;
144
+ width: 40px;
145
+ height: 40px;
146
+ display: flex;
147
+ align-items: center;
148
+ justify-content: center;
149
+ img {
150
+ border-radius: 4px;
151
+ border: 1px solid #eee;
152
+ object-fit: contain;
153
+ }
154
+ }
155
+
156
+ .org-name {
157
+ font-size: 14px;
158
+ flex: 1;
159
+ }
160
+
161
+ &:last-child {
162
+ border-bottom: none;
163
+ }
164
+ }
165
+
166
+ .action-buttons {
167
+ padding: 16px;
168
+ display: flex;
169
+ justify-content: center;
170
+
171
+ .confirm-button {
172
+ background-color: var(--van-primary-color);
173
+ color: white;
174
+ padding: 10px 0;
175
+ border-radius: 4px;
176
+ text-align: center;
177
+ width: 100%;
178
+ font-size: 14px;
179
+ }
180
+ }
181
+ }