@lm_fe/components 0.1.201 → 0.2.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 (187) hide show
  1. package/README.md +1 -1
  2. package/dist/keep-alive/common.d.ts +46 -0
  3. package/dist/keep-alive/components/AsyncComponent.d.ts +27 -0
  4. package/dist/keep-alive/components/Comment.d.ts +18 -0
  5. package/dist/keep-alive/components/Consumer.d.ts +20 -0
  6. package/dist/keep-alive/components/keepAlive.d.ts +4 -0
  7. package/dist/keep-alive/components/provider.d.ts +31 -0
  8. package/dist/keep-alive/contexts/IdentificationContext.d.ts +12 -0
  9. package/dist/keep-alive/contexts/KeepAliveContext.d.ts +5 -0
  10. package/dist/keep-alive/index.d.ts +7 -0
  11. package/dist/keep-alive/index.js +1901 -0
  12. package/dist/keep-alive/utils/bindLifecycle.d.ts +3 -0
  13. package/dist/keep-alive/utils/changePositionByComment.d.ts +1 -0
  14. package/dist/keep-alive/utils/createEventEmitter.d.ts +11 -0
  15. package/dist/keep-alive/utils/createStoreElement.d.ts +1 -0
  16. package/dist/keep-alive/utils/createUniqueIdentification.d.ts +8 -0
  17. package/dist/keep-alive/utils/debug.d.ts +3 -0
  18. package/dist/keep-alive/utils/getDisplayName.d.ts +2 -0
  19. package/dist/keep-alive/utils/getKeepAlive.d.ts +3 -0
  20. package/dist/keep-alive/utils/getKeyByFiberNode.d.ts +1 -0
  21. package/dist/keep-alive/utils/isRegExp.d.ts +1 -0
  22. package/dist/keep-alive/utils/keepAliveDecorator.d.ts +17 -0
  23. package/dist/keep-alive/utils/md5.d.ts +1 -0
  24. package/dist/keep-alive/utils/noop.d.ts +2 -0
  25. package/dist/keep-alive/utils/shallowEqual.d.ts +2 -0
  26. package/dist/keep-alive/utils/useKeepAliveEffect.d.ts +2 -0
  27. package/dist/keep-alive/utils/withIdentificationContextConsumer.d.ts +10 -0
  28. package/dist/keep-alive/utils/withKeepAliveContextConsumer.d.ts +10 -0
  29. package/dist/src/ArraySingle/Inner.d.ts +3 -0
  30. package/dist/src/ArraySingle/index.d.ts +2 -0
  31. package/dist/src/CaseTempleteEdit/Inner.d.ts +4 -0
  32. package/dist/src/CaseTempleteEdit/config.d.ts +20 -0
  33. package/dist/src/CaseTempleteEdit/index.d.ts +4 -0
  34. package/dist/src/CaseTempleteEdit/types.d.ts +19 -0
  35. package/dist/src/CaseTempleteEdit/utils.d.ts +2 -0
  36. package/dist/src/CaseTempleteEditEmr/Inner.d.ts +3 -0
  37. package/dist/src/CaseTempleteEditEmr/demo_text.d.ts +1 -0
  38. package/dist/src/CaseTempleteEditEmr/index.d.ts +2 -0
  39. package/dist/src/CaseTempleteEditEmr/types.d.ts +6 -0
  40. package/dist/src/CaseTempleteEditEmr/utils.d.ts +3 -0
  41. package/dist/{GlobalModal → src/GlobalModal}/index.d.ts +2 -1
  42. package/dist/src/LazyAntd/index.d.ts +17 -0
  43. package/dist/{Monaco → src/Monaco}/Inner.d.ts +1 -1
  44. package/dist/src/MyAddress/Inner.d.ts +3 -0
  45. package/dist/{MyImageEditor → src/MyImageEditor}/Inner.d.ts +1 -1
  46. package/dist/{MyImageEditor → src/MyImageEditor}/utils.d.ts +1 -1
  47. package/dist/{MyInput → src/MyInput}/index.d.ts +2 -2
  48. package/dist/{PDF_Frame_View → src/PDF_Frame_View}/utils.d.ts +1 -1
  49. package/dist/src/PatientSelect/Inner.d.ts +16 -0
  50. package/dist/src/PatientSelect/index.d.ts +3 -0
  51. package/dist/src/SimpleForm/Inner.d.ts +5 -0
  52. package/dist/{SimpleForm → src/SimpleForm}/components/TabForm/index.d.ts +3 -2
  53. package/dist/{SimpleForm → src/SimpleForm}/components/extra/Custom.d.ts +2 -1
  54. package/dist/{SimpleForm → src/SimpleForm}/components/index.d.ts +3 -6
  55. package/dist/src/SimpleForm/index.d.ts +17 -0
  56. package/dist/{SimpleForm/index.d.ts → src/SimpleForm/types.d.ts} +0 -14
  57. package/dist/src/a_chunks/ArraySingle.Inner.js +19 -0
  58. package/dist/src/a_chunks/CaseTempleteEdit.Inner.js +622 -0
  59. package/dist/src/a_chunks/CaseTempleteEditEmr.Inner.js +235 -0
  60. package/dist/{a_chunks/.root6.js → src/a_chunks/MyAddress.Inner.js} +38 -89
  61. package/dist/{a_chunks/.root4.js → src/a_chunks/MyImageEditor.Inner.js} +128 -179
  62. package/dist/{a_chunks/.root5.js → src/a_chunks/Old.InnerOld.js} +20 -59
  63. package/dist/{a_chunks/.root2.js → src/a_chunks/PDF_Frame_View.Inner.js} +11 -51
  64. package/dist/src/a_chunks/PatientSelect.Inner.js +281 -0
  65. package/dist/src/a_chunks/SimpleForm.Inner.js +318 -0
  66. package/dist/src/a_chunks/index.js +550 -0
  67. package/dist/src/a_chunks/style-inject.es.js +25 -0
  68. package/dist/src/config.d.ts +1 -0
  69. package/dist/{hooks → src/hooks}/index.d.ts +1 -0
  70. package/dist/src/hooks/use_fuck.d.ts +5 -0
  71. package/dist/src/index.d.ts +11 -0
  72. package/dist/src/index.js +10 -0
  73. package/dist/src/pack_components.d.ts +213 -0
  74. package/dist/src/utils/getInputStyle.d.ts +1 -0
  75. package/dist/src/utils/index.d.ts +1 -0
  76. package/dist/src/utils/other.d.ts +3 -0
  77. package/package.json +30 -26
  78. package/dist/ContainerDimensions2/index.d.ts +0 -10
  79. package/dist/LazyAntd/AutoComplete/Inner.d.ts +0 -4
  80. package/dist/LazyAntd/AutoComplete/index.d.ts +0 -4
  81. package/dist/LazyAntd/DatePicker/Base/Calendar.d.ts +0 -3
  82. package/dist/LazyAntd/DatePicker/Base/DatePicker.d.ts +0 -11
  83. package/dist/LazyAntd/DatePicker/Base/index.d.ts +0 -12
  84. package/dist/LazyAntd/DatePicker/Base/props.d.ts +0 -14
  85. package/dist/LazyAntd/DatePicker/Calendar.d.ts +0 -4
  86. package/dist/LazyAntd/DatePicker/DatePicker.d.ts +0 -4
  87. package/dist/LazyAntd/DatePicker/MonthPicker.d.ts +0 -4
  88. package/dist/LazyAntd/DatePicker/RangePicker.d.ts +0 -4
  89. package/dist/LazyAntd/DatePicker/TimePicker.d.ts +0 -4
  90. package/dist/LazyAntd/DatePicker/index.d.ts +0 -5
  91. package/dist/LazyAntd/Dropdown/Button.d.ts +0 -2
  92. package/dist/LazyAntd/Dropdown/Inner.d.ts +0 -3
  93. package/dist/LazyAntd/Dropdown/index.d.ts +0 -10
  94. package/dist/LazyAntd/Form/FormItemInner.d.ts +0 -2
  95. package/dist/LazyAntd/Form/Inner.d.ts +0 -3
  96. package/dist/LazyAntd/Form/index.d.ts +0 -9
  97. package/dist/LazyAntd/Modal/Inner.d.ts +0 -4
  98. package/dist/LazyAntd/Modal/index.d.ts +0 -3
  99. package/dist/LazyAntd/Pagination/Inner.d.ts +0 -3
  100. package/dist/LazyAntd/Pagination/index.d.ts +0 -3
  101. package/dist/LazyAntd/Select/Inner.d.ts +0 -3
  102. package/dist/LazyAntd/Select/OptionInner.d.ts +0 -2
  103. package/dist/LazyAntd/Select/index.d.ts +0 -10
  104. package/dist/LazyAntd/Table/Inner.d.ts +0 -3
  105. package/dist/LazyAntd/Table/index.d.ts +0 -3
  106. package/dist/LazyAntd/Tree/DirectoryTreeInner.d.ts +0 -3
  107. package/dist/LazyAntd/Tree/Inner.d.ts +0 -3
  108. package/dist/LazyAntd/Tree/TreeNodeInner.d.ts +0 -4
  109. package/dist/LazyAntd/Tree/index.d.ts +0 -12
  110. package/dist/LazyAntd/TreeSelect/Inner.d.ts +0 -3
  111. package/dist/LazyAntd/TreeSelect/index.d.ts +0 -3
  112. package/dist/LazyAntd/index.d.ts +0 -25
  113. package/dist/MyAddress/Inner.d.ts +0 -3
  114. package/dist/QRCode/Inner.d.ts +0 -3
  115. package/dist/QRCode/index.d.ts +0 -2
  116. package/dist/QRCode/types.d.ts +0 -68
  117. package/dist/a_chunks/.root.js +0 -805
  118. package/dist/a_chunks/.root.js.map +0 -1
  119. package/dist/a_chunks/.root10.js +0 -8
  120. package/dist/a_chunks/.root10.js.map +0 -1
  121. package/dist/a_chunks/.root11.js +0 -7
  122. package/dist/a_chunks/.root11.js.map +0 -1
  123. package/dist/a_chunks/.root12.js +0 -8
  124. package/dist/a_chunks/.root12.js.map +0 -1
  125. package/dist/a_chunks/.root13.js +0 -4
  126. package/dist/a_chunks/.root13.js.map +0 -1
  127. package/dist/a_chunks/.root14.js +0 -8
  128. package/dist/a_chunks/.root14.js.map +0 -1
  129. package/dist/a_chunks/.root15.js +0 -7
  130. package/dist/a_chunks/.root15.js.map +0 -1
  131. package/dist/a_chunks/.root16.js +0 -8
  132. package/dist/a_chunks/.root16.js.map +0 -1
  133. package/dist/a_chunks/.root17.js +0 -8
  134. package/dist/a_chunks/.root17.js.map +0 -1
  135. package/dist/a_chunks/.root18.js +0 -8
  136. package/dist/a_chunks/.root18.js.map +0 -1
  137. package/dist/a_chunks/.root19.js +0 -8
  138. package/dist/a_chunks/.root19.js.map +0 -1
  139. package/dist/a_chunks/.root2.js.map +0 -1
  140. package/dist/a_chunks/.root20.js +0 -6
  141. package/dist/a_chunks/.root20.js.map +0 -1
  142. package/dist/a_chunks/.root21.js +0 -5
  143. package/dist/a_chunks/.root21.js.map +0 -1
  144. package/dist/a_chunks/.root3.js +0 -7
  145. package/dist/a_chunks/.root3.js.map +0 -1
  146. package/dist/a_chunks/.root4.js.map +0 -1
  147. package/dist/a_chunks/.root5.js.map +0 -1
  148. package/dist/a_chunks/.root6.js.map +0 -1
  149. package/dist/a_chunks/.root7.js +0 -8
  150. package/dist/a_chunks/.root7.js.map +0 -1
  151. package/dist/a_chunks/.root8.js +0 -8
  152. package/dist/a_chunks/.root8.js.map +0 -1
  153. package/dist/a_chunks/.root9.js +0 -7
  154. package/dist/a_chunks/.root9.js.map +0 -1
  155. package/dist/a_chunks/index.js +0 -1238
  156. package/dist/a_chunks/index.js.map +0 -1
  157. package/dist/index.d.ts +0 -11
  158. package/dist/index.js +0 -45
  159. package/dist/index.js.map +0 -1
  160. package/dist/pack_components.d.ts +0 -17
  161. package/dist/utils/getInputStyle.d.ts +0 -11
  162. package/dist/utils/index.d.ts +0 -2
  163. package/dist/utils/other.d.ts +0 -4
  164. /package/dist/{ContainerDimensions → src/ContainerDimensions}/index.d.ts +0 -0
  165. /package/dist/{GlobalModal → src/GlobalModal}/utils.d.ts +0 -0
  166. /package/dist/{Monaco → src/Monaco}/index.d.ts +0 -0
  167. /package/dist/{MyAddress → src/MyAddress}/Old/InnerOld.d.ts +0 -0
  168. /package/dist/{MyAddress → src/MyAddress}/Old/index.d.ts +0 -0
  169. /package/dist/{MyAddress → src/MyAddress}/Old/options.d.ts +0 -0
  170. /package/dist/{MyAddress → src/MyAddress}/index.d.ts +0 -0
  171. /package/dist/{MyAddress → src/MyAddress}/type.d.ts +0 -0
  172. /package/dist/{MyAddress → src/MyAddress}/utils.d.ts +0 -0
  173. /package/dist/{MyImageEditor → src/MyImageEditor}/index.d.ts +0 -0
  174. /package/dist/{MyImageEditor → src/MyImageEditor}/init_delete_control.d.ts +0 -0
  175. /package/dist/{MyInput → src/MyInput}/types.d.ts +0 -0
  176. /package/dist/{MyLazyComponent → src/MyLazyComponent}/index.d.ts +0 -0
  177. /package/dist/{PDF_Frame_View → src/PDF_Frame_View}/Inner.d.ts +0 -0
  178. /package/dist/{PDF_Frame_View → src/PDF_Frame_View}/index.d.ts +0 -0
  179. /package/dist/{PDF_Frame_View → src/PDF_Frame_View}/types.d.ts +0 -0
  180. /package/dist/{SimpleForm → src/SimpleForm}/components/extra/MultiInput.d.ts +0 -0
  181. /package/dist/{SimpleForm → src/SimpleForm}/components/extra/SimpleSelect.d.ts +0 -0
  182. /package/dist/{SimpleForm → src/SimpleForm}/components/extra/SwitchSelect.d.ts +0 -0
  183. /package/dist/{SimpleForm → src/SimpleForm}/types/help.d.ts +0 -0
  184. /package/dist/{SimpleForm → src/SimpleForm}/types/metaTypes.d.ts +0 -0
  185. /package/dist/{hooks → src/hooks}/useMchcDriverStatus.d.ts +0 -0
  186. /package/dist/{hooks → src/hooks}/useMyEffect.d.ts +0 -0
  187. /package/dist/{style → src/style}/index.d.ts +0 -0
@@ -0,0 +1,550 @@
1
+ import _defineProperty from "@babel/runtime/helpers/defineProperty";
2
+ import _asyncToGenerator from "@babel/runtime/helpers/asyncToGenerator";
3
+ import _slicedToArray from "@babel/runtime/helpers/slicedToArray";
4
+ import _regeneratorRuntime from "@babel/runtime/regenerator";
5
+ function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
6
+ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
7
+ import { getMonacoLoaderPath, mchcEnv, mchcDriver, address_options, mchcEvent, mchcMacro, ds } from '@lm_fe/env';
8
+ import { MyMonaco, form_validate, Tree_L, TreeSelect_L, Select_L, Table_L, Dropdown_L, Pagination_L, ArraySingle as ArraySingle$1, packs } from '@noah-libjs/components';
9
+ import React, { useEffect, useState, lazy, Suspense } from 'react';
10
+ import { map, get } from 'lodash';
11
+ import { Skeleton } from 'antd';
12
+ import { lm_pdfjs_info } from '@lm_fe/static';
13
+ import { SLocal_SystemConfig } from '@lm_fe/service';
14
+ import { peek_provoke } from '@lm_fe/provoke';
15
+ import { load_src, sleep } from '@lm_fe/utils';
16
+
17
+ // export * from './style'
18
+ MyMonaco.config(getMonacoLoaderPath());
19
+
20
+ // const useMyEffect = mchcEnv.isSp ? useEffect : MyKeepAlive.useKeepAliveEffect
21
+ var useMyEffect = useEffect;
22
+ var useMyEffectSafe = function useMyEffectSafe(props) {
23
+ if (mchcEnv.is_single || props.is_modal) {
24
+ return useEffect;
25
+ }
26
+ return useEffect;
27
+ // return mchcEnv.isSp ? useEffect : MyKeepAlive.useKeepAliveEffect
28
+ };
29
+ function useMchcDriverStatus() {
30
+ var _useState = useState(false),
31
+ _useState2 = _slicedToArray(_useState, 2),
32
+ isOpen = _useState2[0],
33
+ setIsOpen = _useState2[1];
34
+ useEffect(function () {
35
+ var id = setInterval(function () {
36
+ setIsOpen(mchcDriver.isOpen);
37
+ }, 2000);
38
+ return function () {
39
+ clearInterval(id);
40
+ };
41
+ }, []);
42
+ return {
43
+ isOpen: isOpen
44
+ };
45
+ }
46
+ function use_fuck(store_k) {
47
+ var fuck_k = store_k ? "fuck_".concat(store_k) : null;
48
+ var _useState3 = useState(fuck_k ? mchcEnv.store.get(fuck_k) : false),
49
+ _useState4 = _slicedToArray(_useState3, 2),
50
+ fuck = _useState4[0],
51
+ _set_fuck = _useState4[1];
52
+ function set_fuck(s) {
53
+ if (fuck_k) {
54
+ mchcEnv.store.set(fuck_k, s);
55
+ }
56
+ _set_fuck(s);
57
+ }
58
+ function toggle_fuck() {
59
+ set_fuck(!fuck);
60
+ }
61
+ return {
62
+ set_fuck: set_fuck,
63
+ toggle_fuck: toggle_fuck,
64
+ fuck: fuck
65
+ };
66
+ }
67
+ function validate_form(_x) {
68
+ return _validate_form.apply(this, arguments);
69
+ }
70
+ function _validate_form() {
71
+ _validate_form = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime.mark(function _callee(f) {
72
+ return _regeneratorRuntime.wrap(function _callee$(_context) {
73
+ while (1) switch (_context.prev = _context.next) {
74
+ case 0:
75
+ _context.prev = 0;
76
+ _context.next = 3;
77
+ return form_validate(f);
78
+ case 3:
79
+ return _context.abrupt("return", _context.sent);
80
+ case 6:
81
+ _context.prev = 6;
82
+ _context.t0 = _context["catch"](0);
83
+ mchcEnv.warning(_context.t0 === null || _context.t0 === void 0 ? void 0 : _context.t0.text);
84
+ return _context.abrupt("return", null);
85
+ case 10:
86
+ case "end":
87
+ return _context.stop();
88
+ }
89
+ }, _callee, null, [[0, 6]]);
90
+ }));
91
+ return _validate_form.apply(this, arguments);
92
+ }
93
+ var LazyAntd = {
94
+ Tree: Tree_L,
95
+ TreeSelect: TreeSelect_L,
96
+ Select: Select_L,
97
+ Table: Table_L,
98
+ Dropdown: Dropdown_L,
99
+ Pagination: Pagination_L
100
+ };
101
+ function get_address_options_base() {
102
+ return _get_address_options_base.apply(this, arguments);
103
+ }
104
+ function _get_address_options_base() {
105
+ _get_address_options_base = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime.mark(function _callee2() {
106
+ var MAINLAND, OVERSEA, HKMOTW, STREETS, _mainland, _hkmotw, _oversea;
107
+ return _regeneratorRuntime.wrap(function _callee2$(_context2) {
108
+ while (1) switch (_context2.prev = _context2.next) {
109
+ case 0:
110
+ _context2.next = 2;
111
+ return address_options.MAINLAND();
112
+ case 2:
113
+ MAINLAND = _context2.sent;
114
+ _context2.next = 5;
115
+ return address_options.OVERSEA();
116
+ case 5:
117
+ OVERSEA = _context2.sent;
118
+ _context2.next = 8;
119
+ return address_options.HKMOTW();
120
+ case 8:
121
+ HKMOTW = _context2.sent;
122
+ _context2.next = 11;
123
+ return address_options.STREETS();
124
+ case 11:
125
+ STREETS = _context2.sent;
126
+ _mainland = Object.keys(MAINLAND).map(function (provinceName) {
127
+ var provinceItem = MAINLAND[provinceName];
128
+ return {
129
+ label: provinceName,
130
+ value: provinceName,
131
+ children: Object.keys(provinceItem).map(function (cityName) {
132
+ var cityItem = provinceItem[cityName];
133
+ return {
134
+ label: cityName,
135
+ value: cityName,
136
+ children: cityItem.map(function (area) {
137
+ var areaItem = STREETS[provinceName] && STREETS[provinceName][cityName] && STREETS[provinceName][cityName][area];
138
+ return {
139
+ label: area,
140
+ value: area,
141
+ children: areaItem && Object.keys(areaItem).map(function (streetName) {
142
+ var streetItem = areaItem[streetName];
143
+ return {
144
+ label: streetName,
145
+ value: streetName,
146
+ children: streetItem.map(function (village) {
147
+ return {
148
+ label: village,
149
+ value: village
150
+ };
151
+ })
152
+ };
153
+ })
154
+ };
155
+ })
156
+ };
157
+ })
158
+ };
159
+ });
160
+ _hkmotw = Object.keys(HKMOTW).map(function (provinceName) {
161
+ var provinceItem = HKMOTW[provinceName];
162
+ return {
163
+ label: provinceName,
164
+ value: provinceName,
165
+ children: Object.keys(provinceItem).map(function (cityName) {
166
+ var cityItem = provinceItem[cityName];
167
+ return {
168
+ label: cityName,
169
+ value: cityName,
170
+ children: cityItem.map(function (area) {
171
+ return {
172
+ label: area,
173
+ value: area
174
+ };
175
+ })
176
+ };
177
+ })
178
+ };
179
+ });
180
+ _oversea = Object.keys(OVERSEA).map(function (provinceName) {
181
+ var provinceItem = OVERSEA[provinceName];
182
+ return {
183
+ label: provinceName,
184
+ value: provinceName,
185
+ children: Object.keys(provinceItem).map(function (cityName) {
186
+ var cityItem = provinceItem[cityName];
187
+ return {
188
+ label: cityItem,
189
+ value: cityItem
190
+ };
191
+ })
192
+ };
193
+ });
194
+ return _context2.abrupt("return", [_mainland, _hkmotw, _oversea]);
195
+ case 16:
196
+ case "end":
197
+ return _context2.stop();
198
+ }
199
+ }, _callee2);
200
+ }));
201
+ return _get_address_options_base.apply(this, arguments);
202
+ }
203
+ function get_options_without_street() {
204
+ return _get_options_without_street.apply(this, arguments);
205
+ }
206
+ function _get_options_without_street() {
207
+ _get_options_without_street = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime.mark(function _callee3() {
208
+ var all, newOptions;
209
+ return _regeneratorRuntime.wrap(function _callee3$(_context3) {
210
+ while (1) switch (_context3.prev = _context3.next) {
211
+ case 0:
212
+ _context3.next = 2;
213
+ return get_address_options_base();
214
+ case 2:
215
+ all = _context3.sent;
216
+ newOptions = map(all, function (option) {
217
+ if (get(option, 'value') === '广东省') {
218
+ return {
219
+ children: map(get(option, 'children'), function (item) {
220
+ return {
221
+ label: get(item, 'label'),
222
+ value: get(item, 'value'),
223
+ children: map(get(item, 'children'), function (city) {
224
+ return {
225
+ label: get(city, 'label'),
226
+ value: get(city, 'value')
227
+ };
228
+ })
229
+ };
230
+ }),
231
+ label: get(option, 'label'),
232
+ value: get(option, 'value')
233
+ };
234
+ }
235
+ return option;
236
+ });
237
+ return _context3.abrupt("return", newOptions);
238
+ case 5:
239
+ case "end":
240
+ return _context3.stop();
241
+ }
242
+ }, _callee3);
243
+ }));
244
+ return _get_options_without_street.apply(this, arguments);
245
+ }
246
+ function get_old_address_options() {
247
+ return _get_old_address_options.apply(this, arguments);
248
+ }
249
+ function _get_old_address_options() {
250
+ _get_old_address_options = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime.mark(function _callee4() {
251
+ var street,
252
+ _args4 = arguments;
253
+ return _regeneratorRuntime.wrap(function _callee4$(_context4) {
254
+ while (1) switch (_context4.prev = _context4.next) {
255
+ case 0:
256
+ street = _args4.length > 0 && _args4[0] !== undefined ? _args4[0] : true;
257
+ return _context4.abrupt("return", street ? get_address_options_base() : get_options_without_street());
258
+ case 2:
259
+ case "end":
260
+ return _context4.stop();
261
+ }
262
+ }, _callee4);
263
+ }));
264
+ return _get_old_address_options.apply(this, arguments);
265
+ }
266
+ var MyAddressOld = /*#__PURE__*/lazy(function () {
267
+ return import('./Old.InnerOld.js');
268
+ });
269
+ var MyAddressNew_ = /*#__PURE__*/lazy(function () {
270
+ return import('./MyAddress.Inner.js');
271
+ });
272
+ function MyAddress(props) {
273
+ if (mchcEnv.is_primary) {
274
+ return /*#__PURE__*/React.createElement(MyAddressNew_, _objectSpread({}, props));
275
+ }
276
+ return /*#__PURE__*/React.createElement(MyAddressOld, _objectSpread({}, props));
277
+ }
278
+ function MyAddressNew(props) {
279
+ return /*#__PURE__*/React.createElement(MyAddressNew_, _objectSpread({}, props));
280
+ }
281
+ var MyLazyComponent = function MyLazyComponent(props) {
282
+ var children = props.children,
283
+ fallback = props.fallback,
284
+ _props$size = props.size,
285
+ size = _props$size === void 0 ? 'small' : _props$size;
286
+ var m = {
287
+ tiny: 2,
288
+ small: 4,
289
+ middle: 8,
290
+ large: 16
291
+ };
292
+ var rows = m[size];
293
+ return /*#__PURE__*/React.createElement(Suspense, {
294
+ fallback: fallback !== null && fallback !== void 0 ? fallback : /*#__PURE__*/React.createElement("div", {
295
+ style: {
296
+ padding: 24
297
+ }
298
+ }, /*#__PURE__*/React.createElement(Skeleton, {
299
+ paragraph: {
300
+ rows: rows
301
+ }
302
+ }))
303
+ }, children);
304
+ };
305
+ var real_fabric = function real_fabric() {
306
+ return window.fabric;
307
+ };
308
+ var default_legends = [{
309
+ img: mchcEnv.gs(function (_) {
310
+ return _.lm_imgs.mie['img1.png'];
311
+ }),
312
+ width: 331,
313
+ height: 144,
314
+ label: '女性外生殖器'
315
+ }, {
316
+ img: mchcEnv.gs(function (_) {
317
+ return _.lm_imgs.mie['img2.png'];
318
+ }),
319
+ width: 305,
320
+ height: 213,
321
+ label: '子宫'
322
+ }, {
323
+ img: mchcEnv.gs(function (_) {
324
+ return _.lm_imgs.mie['img3.png'];
325
+ }),
326
+ width: 68,
327
+ height: 67,
328
+ label: '细菌'
329
+ }, {
330
+ img: mchcEnv.gs(function (_) {
331
+ return _.lm_imgs.mie['img4.png'];
332
+ }),
333
+ width: 52,
334
+ height: 59,
335
+ label: '宫颈癌病毒'
336
+ }, {
337
+ img: mchcEnv.gs(function (_) {
338
+ return _.lm_imgs.mie['img5.png'];
339
+ }),
340
+ width: 70,
341
+ height: 70,
342
+ label: '阴道滴虫'
343
+ }];
344
+ var MyImageEditorEvents = {
345
+ save: 'mie:save',
346
+ create: 'mie:create'
347
+ };
348
+ function event_process(con, __events) {
349
+ con.on('drop', __events.drop).on('mouse:down', __events['mouse:down']).on('mouse:move', __events['mouse:move']).on('mouse:up', __events['mouse:up']).on('mouse:over', __events['mouse:over']).on('mouse:out', __events['mouse:out']).on('object:added', __events['object:added']);
350
+ return function () {
351
+ con.off('drop', __events.drop).off('mouse:down', __events['mouse:down']).off('mouse:move', __events['mouse:move']).off('mouse:up', __events['mouse:up']).off('mouse:over', __events['mouse:over']).off('mouse:out', __events['mouse:out']).off('object:added', __events['object:added']);
352
+ };
353
+ }
354
+ var GynaecologyImageEditorInner = /*#__PURE__*/lazy(function () {
355
+ return import('./MyImageEditor.Inner.js');
356
+ });
357
+ function MyImageEditor__(props) {
358
+ return /*#__PURE__*/React.createElement(MyLazyComponent, null, /*#__PURE__*/React.createElement(GynaecologyImageEditorInner, _objectSpread({}, props)));
359
+ }
360
+ var MyImageEditor = Object.assign(MyImageEditor__, {
361
+ events: MyImageEditorEvents
362
+ });
363
+ var GynaecologyImageEditor = MyImageEditor;
364
+ var PatientSelect = /*#__PURE__*/lazy(function () {
365
+ return import('./PatientSelect.Inner.js');
366
+ });
367
+ function usePatientSelect(name) {
368
+ var _useState5 = useState(),
369
+ _useState6 = _slicedToArray(_useState5, 2),
370
+ data = _useState6[0],
371
+ setData = _useState6[1];
372
+ useEffect(function () {
373
+ return mchcEvent.on_rm('my_form', function (e) {
374
+ if (e.type !== 'onSearch' || e.name !== name || !e.value.data) return;
375
+ setData(e.value.data);
376
+ });
377
+ }, []);
378
+ return [data];
379
+ }
380
+ var ArraySingle = /*#__PURE__*/lazy(function () {
381
+ return import('./ArraySingle.Inner.js');
382
+ });
383
+ ArraySingle.DisplayFC = ArraySingle$1.DisplayFC;
384
+ var pack_components = _objectSpread(_objectSpread({}, packs), {}, {
385
+ MyAddress: MyAddress,
386
+ MyImageEditor: MyImageEditor,
387
+ ArraySingle: ArraySingle,
388
+ PatientSelect: PatientSelect
389
+ });
390
+ function convertDataURIToBinary(dataURI) {
391
+ var raw = window.atob(dataURI);
392
+ var rawLength = raw.length;
393
+ var array = new Uint8Array(new ArrayBuffer(rawLength));
394
+ for (var i = 0; i < rawLength; i++) {
395
+ array[i] = raw.charCodeAt(i);
396
+ }
397
+ return array;
398
+ }
399
+ var metaHead = 'data:application/pdf;base64,';
400
+ function handlePrintData(printData) {
401
+ var noHeadData = printData.startsWith(metaHead) ? printData.slice(metaHead.length) : printData;
402
+ return convertDataURIToBinary(noHeadData);
403
+ }
404
+ function handleRes(res) {
405
+ var _resData$filepath;
406
+ var resData;
407
+ if (!res) return {};
408
+ if (typeof res.code === 'number') {
409
+ resData = res.data;
410
+ } else {
411
+ resData = res;
412
+ }
413
+ if (!resData) return {};
414
+ var _resData = resData,
415
+ pdfdata = _resData.pdfdata,
416
+ filepath = _resData.filepath,
417
+ imagesData = _resData.imagesData;
418
+ resData.filepath = filepath && "".concat(location.origin).concat(filepath);
419
+ resData.pdfdata = pdfdata && handlePrintData(pdfdata);
420
+ resData.imagesData = imagesData !== null && imagesData !== void 0 ? imagesData : [];
421
+ // .map(_ => `data:image/png;base64,${_}`)
422
+ return {
423
+ pdf: (_resData$filepath = resData.filepath) !== null && _resData$filepath !== void 0 ? _resData$filepath : resData.pdfdata,
424
+ images: resData.imagesData
425
+ };
426
+ }
427
+ function get_PdfFrameView_version() {
428
+ return SLocal_SystemConfig.get('PDF预览组件版本') || lm_pdfjs_info.dirs['3.11.174'];
429
+ }
430
+ var PdfFrameViewInner = /*#__PURE__*/lazy(function () {
431
+ return import('./PDF_Frame_View.Inner.js');
432
+ });
433
+ function PdfFrameView(props) {
434
+ return /*#__PURE__*/React.createElement(Suspense, {
435
+ fallback: "\u52A0\u8F7D\u4E2D..."
436
+ }, /*#__PURE__*/React.createElement(PdfFrameViewInner, _objectSpread({}, props)));
437
+ }
438
+ var Inner = /*#__PURE__*/lazy(function () {
439
+ return import('./SimpleForm.Inner.js');
440
+ });
441
+ //@ts-ignore
442
+ var SimpleForm = Inner;
443
+ SimpleForm.getPresetRules = function (name, required) {
444
+ return [_objectSpread({
445
+ required: required
446
+ }, basicRules[name])];
447
+ };
448
+ SimpleForm.requiredRules = [{
449
+ required: true,
450
+ message: ''
451
+ }];
452
+ var basicRules = {
453
+ telephone: {
454
+ validator: function validator(_, value) {
455
+ return /^1([0-9][0-9]|4[579]|66|7[0135678]|9[89])[0-9]{8}$/.test(value) ? Promise.resolve() : Promise.reject();
456
+ },
457
+ message: '请输入手机号'
458
+ }
459
+ };
460
+ var loaded$1 = false;
461
+ function get_editor_frame() {
462
+ var _emr_el = document.getElementById('_emreditor');
463
+ return _emr_el;
464
+ }
465
+ function load_xemr() {
466
+ return _load_xemr.apply(this, arguments);
467
+ }
468
+ function _load_xemr() {
469
+ _load_xemr = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime.mark(function _callee5() {
470
+ var pp, emr_base, emr_vender;
471
+ return _regeneratorRuntime.wrap(function _callee5$(_context5) {
472
+ while (1) switch (_context5.prev = _context5.next) {
473
+ case 0:
474
+ if (loaded$1) {
475
+ _context5.next = 10;
476
+ break;
477
+ }
478
+ pp = mchcMacro.PUBLIC_PATH;
479
+ emr_base = "".concat(pp, "lib/X-EMR");
480
+ emr_vender = "".concat(emr_base, "/vender");
481
+ load_src({
482
+ text: "#_printview {display: none !important;} #_emreditor {display: block !important;}",
483
+ type: 'text/css'
484
+ });
485
+ _context5.next = 7;
486
+ return ds(["".concat(emr_base, "/stylesheets/editor.css"), "".concat(emr_vender, "/jquery/zTreeStyle/zTreeStyle.css"), "".concat(emr_vender, "/jquery/jquery.js"), "".concat(emr_vender, "/jquery/jquery.ztree.core.min.js"), "".concat(emr_vender, "/jquery/jquery.ztree.exedit.min.js"), "".concat(emr_vender, "/jquery/jquery.ztree.exhide.min.js"), "".concat(emr_vender, "/fabric.js"), "".concat(emr_vender, "/date97/WdatePicker.js"), "".concat(emr_vender, "/codemirror.js"), "".concat(emr_base, "/js/editor.js")]);
487
+ case 7:
488
+ loaded$1 = true;
489
+ _context5.next = 10;
490
+ return sleep(1000);
491
+ case 10:
492
+ return _context5.abrupt("return", window['editor']);
493
+ case 11:
494
+ case "end":
495
+ return _context5.stop();
496
+ }
497
+ }, _callee5);
498
+ }));
499
+ return _load_xemr.apply(this, arguments);
500
+ }
501
+ var loaded = false;
502
+ function load_sde() {
503
+ return _load_sde.apply(this, arguments);
504
+ }
505
+ function _load_sde() {
506
+ _load_sde = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime.mark(function _callee6() {
507
+ var pp;
508
+ return _regeneratorRuntime.wrap(function _callee6$(_context6) {
509
+ while (1) switch (_context6.prev = _context6.next) {
510
+ case 0:
511
+ if (loaded) {
512
+ _context6.next = 7;
513
+ break;
514
+ }
515
+ pp = mchcMacro.PUBLIC_PATH;
516
+ _context6.next = 4;
517
+ return ds(["".concat(pp, "lib/sde.config.js"), "".concat(pp, "lib/ueditor/ueditor.all.min.js"), "".concat(pp, "lib/ueditor/lang/zh-cn/zh-cn.js"), "".concat(pp, "lib/ueditor/themes/default/css/ueditor.css"), "".concat(pp, "lib/sde/sde-ie8-design.js")]);
518
+ case 4:
519
+ loaded = true;
520
+ _context6.next = 7;
521
+ return sleep(1000);
522
+ case 7:
523
+ case "end":
524
+ return _context6.stop();
525
+ }
526
+ }, _callee6);
527
+ }));
528
+ return _load_sde.apply(this, arguments);
529
+ }
530
+ function preload_tpl_editor() {
531
+ var config = peek_provoke('config');
532
+ if (config.模板编辑器 === 'XEMR') {
533
+ load_xemr();
534
+ } else {
535
+ load_sde();
536
+ }
537
+ }
538
+ var CaseTempleteEdit = /*#__PURE__*/lazy(function () {
539
+ return import('./CaseTempleteEdit.Inner.js');
540
+ });
541
+ var CaseTempleteEditEmr = /*#__PURE__*/lazy(function () {
542
+ return import('./CaseTempleteEditEmr.Inner.js');
543
+ });
544
+
545
+ // export * from './style'
546
+ function get_echarat() {
547
+ return import('echarts');
548
+ }
549
+ window.get_echarat = get_echarat;
550
+ export { CaseTempleteEditEmr as C, GynaecologyImageEditor as G, LazyAntd as L, MyImageEditorEvents as M, PatientSelect as P, SimpleForm as S, handleRes as a, load_xemr as b, get_editor_frame as c, get_old_address_options as d, event_process as e, default_legends as f, get_PdfFrameView_version as g, handlePrintData as h, get_echarat as i, useMyEffectSafe as j, useMchcDriverStatus as k, load_sde as l, use_fuck as m, MyAddress as n, MyAddressNew as o, pack_components as p, MyAddressOld as q, real_fabric as r, MyImageEditor as s, usePatientSelect as t, useMyEffect as u, validate_form as v, PdfFrameView as w, CaseTempleteEdit as x, preload_tpl_editor as y };
@@ -0,0 +1,25 @@
1
+ function styleInject(css, ref) {
2
+ if (ref === void 0) ref = {};
3
+ var insertAt = ref.insertAt;
4
+ if (!css || typeof document === 'undefined') {
5
+ return;
6
+ }
7
+ var head = document.head || document.getElementsByTagName('head')[0];
8
+ var style = document.createElement('style');
9
+ style.type = 'text/css';
10
+ if (insertAt === 'top') {
11
+ if (head.firstChild) {
12
+ head.insertBefore(style, head.firstChild);
13
+ } else {
14
+ head.appendChild(style);
15
+ }
16
+ } else {
17
+ head.appendChild(style);
18
+ }
19
+ if (style.styleSheet) {
20
+ style.styleSheet.cssText = css;
21
+ } else {
22
+ style.appendChild(document.createTextNode(css));
23
+ }
24
+ }
25
+ export { styleInject as s };
@@ -0,0 +1 @@
1
+ export {};
@@ -1,2 +1,3 @@
1
1
  export * from './useMyEffect';
2
2
  export * from './useMchcDriverStatus';
3
+ export * from './use_fuck';
@@ -0,0 +1,5 @@
1
+ export declare function use_fuck(store_k?: string): {
2
+ set_fuck: (s: boolean) => void;
3
+ toggle_fuck: () => void;
4
+ fuck: any;
5
+ };
@@ -0,0 +1,11 @@
1
+ import './config';
2
+ export * from '@noah-libjs/components';
3
+ export * from './hooks';
4
+ export * from './utils';
5
+ export * from './LazyAntd';
6
+ export * from './pack_components';
7
+ export * from './PDF_Frame_View';
8
+ export * from './SimpleForm';
9
+ export * from './CaseTempleteEdit';
10
+ export * from './CaseTempleteEditEmr';
11
+ export declare function get_echarat(): Promise<typeof import("echarts/types/dist/echarts")>;
@@ -0,0 +1,10 @@
1
+ export { x as CaseTempleteEdit, C as CaseTempleteEditEmr, G as GynaecologyImageEditor, L as LazyAntd, n as MyAddress, o as MyAddressNew, q as MyAddressOld, s as MyImageEditor, M as MyImageEditorEvents, P as PatientSelect, w as PdfFrameView, S as SimpleForm, g as get_PdfFrameView_version, i as get_echarat, d as get_old_address_options, p as pack_components, y as preload_tpl_editor, k as useMchcDriverStatus, u as useMyEffect, j as useMyEffectSafe, t as usePatientSelect, m as use_fuck, v as validate_form } from './a_chunks/index.js';
2
+ export * from '@noah-libjs/components';
3
+ import '@lm_fe/env';
4
+ import 'react';
5
+ import 'lodash';
6
+ import 'antd';
7
+ import '@lm_fe/static';
8
+ import '@lm_fe/service';
9
+ import '@lm_fe/provoke';
10
+ import '@lm_fe/utils';