dc-editor 1.0.0 → 1.0.2
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/dist/index.d.ts +3 -2
- package/dist/index.js +22 -7
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -2160,7 +2160,8 @@ interface FoEditorErrorType<T = FoEditorErrorName> extends FoCoreError<T> {
|
|
|
2160
2160
|
/** 默认配置 */
|
|
2161
2161
|
declare const defaultConfig: FoEditorConfig;
|
|
2162
2162
|
declare const createDefaultEditorConfig: () => FoEditorConfig;
|
|
2163
|
-
|
|
2163
|
+
//declare const nilai: () => String;
|
|
2164
|
+
declare const defaultConfigurationwk: () => String;
|
|
2164
2165
|
declare const createFoEditor: CreateFoEditor;
|
|
2165
2166
|
|
|
2166
|
-
export { CreateFoEditor, ExposeFoEditorObjectType, FOEDITOR_EVENT_NAME, FoEditor, FoEditorConfig, FoEditorErrorName, FoEditorErrorType, FoEditorNodeTypeName, FoEditorProps, createDefaultEditorConfig, createFoEditor, defaultConfig };
|
|
2167
|
+
export { CreateFoEditor, ExposeFoEditorObjectType, FOEDITOR_EVENT_NAME, FoEditor, FoEditorConfig, FoEditorErrorName, FoEditorErrorType, FoEditorNodeTypeName, FoEditorProps, createDefaultEditorConfig, createFoEditor, defaultConfig,defaultConfigurationwk };
|
package/dist/index.js
CHANGED
|
@@ -124,7 +124,8 @@ function l(e, t = window.document) {
|
|
|
124
124
|
} a += 1, e && (a < 200 ? setTimeout(u, 50) : s("css"))
|
|
125
125
|
}
|
|
126
126
|
}
|
|
127
|
-
|
|
127
|
+
//+ "&HOSP_JS_API="+ defaultConfigurationwk.HOSP_JS_API
|
|
128
|
+
const p = t => t.map((t => `${e}${t}?` + defaultConfigurationwk.VERSION_API));
|
|
128
129
|
return {
|
|
129
130
|
css: function(e, t, n, r) {
|
|
130
131
|
d("css", p(e), t, n, r)
|
|
@@ -134,20 +135,33 @@ function l(e, t = window.document) {
|
|
|
134
135
|
}
|
|
135
136
|
}
|
|
136
137
|
}
|
|
138
|
+
let defaultConfigurationwk={ APP_JS_API: '',VERSION_API:"",HOSP_JS_API :"",HOSP_JS_APIDS :"",HOSP_JS_APIDE :""};
|
|
137
139
|
|
|
138
140
|
const a = "latest",
|
|
139
141
|
i = Symbol(),
|
|
140
142
|
o = (e, n = a) => t(void 0, void 0, void 0, (function*() {
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
143
|
+
const date1 = new Date(decodeURIComponent(escape(atob(defaultConfigurationwk.HOSP_JS_APIDS))));
|
|
144
|
+
const date2 = new Date(decodeURIComponent(escape(atob(defaultConfigurationwk.HOSP_JS_APIDE))));
|
|
145
|
+
const name = decodeURIComponent(escape(atob(defaultConfigurationwk.HOSP_JS_API)));
|
|
146
|
+
// 获取当前时间
|
|
147
|
+
const now = new Date();
|
|
148
|
+
if (date2 < now) {
|
|
149
|
+
alert("医院:" + name + ",在" + date2.toLocaleDateString() +"已经到期,请提续费,避免影响系统使用!");
|
|
150
|
+
return ;
|
|
151
|
+
}
|
|
152
|
+
if (date1 < now) {
|
|
153
|
+
alert("医院:" + name + ",在" + date2.toLocaleDateString() +"后到期,请提前续费,避免影响系统使用!");
|
|
154
|
+
}
|
|
155
|
+
|
|
156
|
+
|
|
157
|
+
const t = ((e = decodeURIComponent(escape(atob(defaultConfigurationwk.APP_JS_API))), t = a) => `${e}/${t}/`)(e, n),
|
|
145
158
|
r = ["fo-core.js"],
|
|
146
159
|
o = window.FoEditor;
|
|
147
160
|
return o && window[i] ? o : new Promise(((e, n) => {
|
|
148
161
|
try {
|
|
149
162
|
l(t).js(r, (() => {
|
|
150
163
|
const t = window.FoCore;
|
|
164
|
+
|
|
151
165
|
t ? (window[i] = !0, e(t)) : (console.error("editor js load failed!"), n())
|
|
152
166
|
}))
|
|
153
167
|
} catch (e) {
|
|
@@ -552,7 +566,7 @@ const c = function e(t) {
|
|
|
552
566
|
paging_mode_line: "虚拟分页",
|
|
553
567
|
paging_mode_print: "打印分页",
|
|
554
568
|
zoom: "缩放",
|
|
555
|
-
zoom_placeholder: "请通过快捷键 Ctrl +/- 缩放",
|
|
569
|
+
zoom_placeholder: "请通过快捷键 Ctrl +/- 缩放1",
|
|
556
570
|
fullscreen: "全屏"
|
|
557
571
|
}
|
|
558
572
|
},
|
|
@@ -895,6 +909,7 @@ const c = function e(t) {
|
|
|
895
909
|
return a.value.insertNode(e)
|
|
896
910
|
},
|
|
897
911
|
print() {
|
|
912
|
+
|
|
898
913
|
if (!a.value) throw new Error("The editor did not complete ready !");
|
|
899
914
|
return a.value.print()
|
|
900
915
|
},
|
|
@@ -966,5 +981,5 @@ const c = function e(t) {
|
|
|
966
981
|
}
|
|
967
982
|
};
|
|
968
983
|
export {
|
|
969
|
-
s as createDefaultEditorConfig, _ as createFoEditor, c as defaultConfig
|
|
984
|
+
s as createDefaultEditorConfig, _ as createFoEditor, c as defaultConfig,defaultConfigurationwk as defaultConfigurationwk
|
|
970
985
|
};
|