vap1 0.3.9 → 0.4.0

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.
@@ -43,7 +43,6 @@ var Image = function (props) {
43
43
  return react_1.default.createElement(ImageView, __assign({}, props));
44
44
  // const editor = useSlateStatic()
45
45
  // const path = ReactEditor.findPath(editor, element)
46
- // // console.log(path)
47
46
  // // const selected = useSelected()
48
47
  // // const focused = useFocused()
49
48
  // return <div {...attributes}>
@@ -28,7 +28,6 @@ var VOID_SET = new Set(['image', 'video', 'audio']);
28
28
  var supportAdvance = function (editor) {
29
29
  var insertData = editor.insertData, isVoid = editor.isVoid;
30
30
  editor.isVoid = function (element) {
31
- // console.log(element.type, VOID_SET.has(element.type))
32
31
  if (VOID_SET.has(element.type))
33
32
  return true;
34
33
  return isVoid(element);
@@ -63,8 +62,6 @@ var supportAdvance = function (editor) {
63
62
  return editor;
64
63
  // editor.insertData = data => {
65
64
  // const text = data.getData('text/plain')
66
- // console.log('insert', data);
67
- // console.log('text', text);
68
65
  // const { files } = data
69
66
  // if (files && files.length > 0) {
70
67
  // for (const file of files) {
package/package.json CHANGED
@@ -1 +1 @@
1
- {"name":"vap1","version":"0.3.9","description":"vap1, Both support MicroService and SAP FrameWork, Support IE>9","main":"index.js","author":"Xiang da","license":"ISC"}
1
+ {"name":"vap1","version":"0.4.0","description":"vap1, Both support MicroService and SAP FrameWork, Support IE>9","main":"index.js","author":"Xiang da","license":"ISC"}
package/utils/PageUtil.js CHANGED
@@ -118,11 +118,18 @@ exports.resolveURL = len == 0 ? DEFAULT_RESOLVER : function (url) {
118
118
  /**
119
119
  * 兼容二级目录-恢复URL
120
120
  */
121
- exports.clearURL = len == 0 ? DEFAULT_RESOLVER : function (url) {
122
- if (!url.startsWith(window.APP_ROOT))
123
- return url;
124
- return url.substring(len);
121
+ var clearURL = function (url) {
122
+ var result = url || '';
123
+ var idx = result.indexOf('?');
124
+ if (result.indexOf('?') >= 0)
125
+ result = result.substring(0, idx);
126
+ if (len == 0)
127
+ return result;
128
+ if (!result.startsWith(window.APP_ROOT))
129
+ return result;
130
+ return result.substring(len);
125
131
  };
132
+ exports.clearURL = clearURL;
126
133
  var GLOBAL_APPS = new Map();
127
134
  /**
128
135
  * 获取当前 APP 名称