@cgboiler/biz-mobile 1.18.17 → 1.18.19

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/es/index.d.ts CHANGED
@@ -8,7 +8,7 @@ declare namespace _default {
8
8
  }
9
9
  export default _default;
10
10
  export function install(app: any): void;
11
- export const version: "1.18.16";
11
+ export const version: "1.18.18";
12
12
  import MdPreview from './md-preview';
13
13
  import OrgPicker from './org-picker';
14
14
  import ProjectSelect from './project-select';
package/es/index.js CHANGED
@@ -2,7 +2,7 @@ import MdPreview from "./md-preview";
2
2
  import OrgPicker from "./org-picker";
3
3
  import ProjectSelect from "./project-select";
4
4
  import RichTextEditor from "./rich-text-editor";
5
- const version = "1.18.16";
5
+ const version = "1.18.18";
6
6
  function install(app) {
7
7
  const components = [
8
8
  MdPreview,
@@ -106,6 +106,20 @@ var stdin_default = defineComponent({
106
106
  }, {
107
107
  deep: true
108
108
  });
109
+ watch(() => props.show, (newValue) => {
110
+ const handleKeyDown = (event) => {
111
+ if (event.key === "Escape") {
112
+ emit("update:show", false);
113
+ }
114
+ };
115
+ if (newValue) {
116
+ window.addEventListener("keydown", handleKeyDown);
117
+ } else {
118
+ window.removeEventListener("keydown", handleKeyDown);
119
+ }
120
+ }, {
121
+ immediate: true
122
+ });
109
123
  const handleDeptSelect = (item) => {
110
124
  if (item.type !== "dept" || !props.multiple)
111
125
  return;
@@ -112,7 +112,7 @@ const useApi = () => {
112
112
  const searchResults = yield fetchData(url);
113
113
  orgSearchList.value = searchResults.filter((item) => item.type !== "user" || item.status !== 5).filter((item, index, self) => index === self.findIndex((other) => other.id === item.id));
114
114
  }), 300);
115
- const MAX_RECENT_SELECTIONS = 15;
115
+ const MAX_RECENT_SELECTIONS = 20;
116
116
  const getRecentUsers = () => __async(void 0, null, function* () {
117
117
  var _a;
118
118
  const user = yield getUserInfo();
package/lib/index.d.ts CHANGED
@@ -8,7 +8,7 @@ declare namespace _default {
8
8
  }
9
9
  export default _default;
10
10
  export function install(app: any): void;
11
- export const version: "1.18.16";
11
+ export const version: "1.18.18";
12
12
  import MdPreview from './md-preview';
13
13
  import OrgPicker from './org-picker';
14
14
  import ProjectSelect from './project-select';
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.18.16";
48
+ const version = "1.18.18";
49
49
  function install(app) {
50
50
  const components = [
51
51
  import_md_preview.default,
@@ -138,6 +138,20 @@ var stdin_default = (0, import_vue2.defineComponent)({
138
138
  }, {
139
139
  deep: true
140
140
  });
141
+ (0, import_vue2.watch)(() => props.show, (newValue) => {
142
+ const handleKeyDown = (event) => {
143
+ if (event.key === "Escape") {
144
+ emit("update:show", false);
145
+ }
146
+ };
147
+ if (newValue) {
148
+ window.addEventListener("keydown", handleKeyDown);
149
+ } else {
150
+ window.removeEventListener("keydown", handleKeyDown);
151
+ }
152
+ }, {
153
+ immediate: true
154
+ });
141
155
  const handleDeptSelect = (item) => {
142
156
  if (item.type !== "dept" || !props.multiple)
143
157
  return;
@@ -135,7 +135,7 @@ const useApi = () => {
135
135
  const searchResults = yield fetchData(url);
136
136
  orgSearchList.value = searchResults.filter((item) => item.type !== "user" || item.status !== 5).filter((item, index, self) => index === self.findIndex((other) => other.id === item.id));
137
137
  }), 300);
138
- const MAX_RECENT_SELECTIONS = 15;
138
+ const MAX_RECENT_SELECTIONS = 20;
139
139
  const getRecentUsers = () => __async(void 0, null, function* () {
140
140
  var _a;
141
141
  const user = yield (0, import_core.getUserInfo)();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cgboiler/biz-mobile",
3
- "version": "1.18.17",
3
+ "version": "1.18.19",
4
4
  "description": "",
5
5
  "main": "lib/index.js",
6
6
  "module": "es/index.js",
@@ -52,7 +52,7 @@
52
52
  "lodash-es": "^4.17.21",
53
53
  "vant": "^4.9.19",
54
54
  "@cgboiler/core": "1.2.10",
55
- "@cgboiler/biz-basic": "1.0.24",
55
+ "@cgboiler/biz-basic": "1.0.39",
56
56
  "@cgboiler/shared": "1.1.2"
57
57
  },
58
58
  "scripts": {