@zzdadelu/schema-builder 1.0.0-alpha.90 → 1.0.0-alpha.91

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/main.js CHANGED
@@ -55,7 +55,7 @@ var Design = function Design(props, ref) {
55
55
  };
56
56
  var engineOnLoad = /*#__PURE__*/function () {
57
57
  var _ref = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee(event) {
58
- var _iframe3, _iframeWindow$__FR_EN;
58
+ var _iframe3, _iframeWindow$, _iframeWindow$3, _iframeWindow$__FR_EN;
59
59
  var iframeWindow, waitForMaterial;
60
60
  return _regenerator().w(function (_context) {
61
61
  while (1) switch (_context.n) {
@@ -74,6 +74,7 @@ var Design = function Design(props, ref) {
74
74
  return _context.a(2);
75
75
  case 2:
76
76
  console.log('iframe init engine: start waiting...');
77
+ console.log('iframe init engine: start waiting...', (_iframeWindow$ = iframeWindow[0]) === null || _iframeWindow$ === void 0 ? void 0 : _iframeWindow$.AliFormRenderMaterial);
77
78
 
78
79
  // 等待 AliFormRenderMaterial 出现
79
80
  waitForMaterial = function waitForMaterial() {
@@ -82,9 +83,9 @@ var Design = function Design(props, ref) {
82
83
  var maxAttempts = 50; // 最长等待 50 * 100ms = 5 秒
83
84
 
84
85
  var timer = setInterval(function () {
85
- var _iframeWindow$;
86
+ var _iframeWindow$2;
86
87
  attempts++;
87
- var material = (_iframeWindow$ = iframeWindow[0]) === null || _iframeWindow$ === void 0 ? void 0 : _iframeWindow$.AliFormRenderMaterial;
88
+ var material = (_iframeWindow$2 = iframeWindow[0]) === null || _iframeWindow$2 === void 0 ? void 0 : _iframeWindow$2.AliFormRenderMaterial;
88
89
  if (material) {
89
90
  console.log('AliFormRenderMaterial is ready:', material);
90
91
  clearInterval(timer);
@@ -102,6 +103,7 @@ var Design = function Design(props, ref) {
102
103
  return waitForMaterial();
103
104
  case 3:
104
105
  console.log('iframe init engine: start init');
106
+ console.log('iframe init engine: start init', (_iframeWindow$3 = iframeWindow[0]) === null || _iframeWindow$3 === void 0 ? void 0 : _iframeWindow$3.AliFormRenderMaterial);
105
107
 
106
108
  // 2) 执行初始化
107
109
  iframeWindow === null || iframeWindow === void 0 ? void 0 : (_iframeWindow$__FR_EN = iframeWindow.__FR_ENGINE__) === null || _iframeWindow$__FR_EN === void 0 ? void 0 : _iframeWindow$__FR_EN.init(_objectSpread({
package/lib/main.js CHANGED
@@ -63,7 +63,7 @@ var Design = function Design(props, ref) {
63
63
  };
64
64
  var engineOnLoad = /*#__PURE__*/function () {
65
65
  var _ref = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee(event) {
66
- var _iframe3, _iframeWindow$__FR_EN;
66
+ var _iframe3, _iframeWindow$, _iframeWindow$3, _iframeWindow$__FR_EN;
67
67
  var iframeWindow, waitForMaterial;
68
68
  return _regenerator().w(function (_context) {
69
69
  while (1) switch (_context.n) {
@@ -82,6 +82,7 @@ var Design = function Design(props, ref) {
82
82
  return _context.a(2);
83
83
  case 2:
84
84
  console.log('iframe init engine: start waiting...');
85
+ console.log('iframe init engine: start waiting...', (_iframeWindow$ = iframeWindow[0]) === null || _iframeWindow$ === void 0 ? void 0 : _iframeWindow$.AliFormRenderMaterial);
85
86
 
86
87
  // 等待 AliFormRenderMaterial 出现
87
88
  waitForMaterial = function waitForMaterial() {
@@ -90,9 +91,9 @@ var Design = function Design(props, ref) {
90
91
  var maxAttempts = 50; // 最长等待 50 * 100ms = 5 秒
91
92
 
92
93
  var timer = setInterval(function () {
93
- var _iframeWindow$;
94
+ var _iframeWindow$2;
94
95
  attempts++;
95
- var material = (_iframeWindow$ = iframeWindow[0]) === null || _iframeWindow$ === void 0 ? void 0 : _iframeWindow$.AliFormRenderMaterial;
96
+ var material = (_iframeWindow$2 = iframeWindow[0]) === null || _iframeWindow$2 === void 0 ? void 0 : _iframeWindow$2.AliFormRenderMaterial;
96
97
  if (material) {
97
98
  console.log('AliFormRenderMaterial is ready:', material);
98
99
  clearInterval(timer);
@@ -110,6 +111,7 @@ var Design = function Design(props, ref) {
110
111
  return waitForMaterial();
111
112
  case 3:
112
113
  console.log('iframe init engine: start init');
114
+ console.log('iframe init engine: start init', (_iframeWindow$3 = iframeWindow[0]) === null || _iframeWindow$3 === void 0 ? void 0 : _iframeWindow$3.AliFormRenderMaterial);
113
115
 
114
116
  // 2) 执行初始化
115
117
  iframeWindow === null || iframeWindow === void 0 ? void 0 : (_iframeWindow$__FR_EN = iframeWindow.__FR_ENGINE__) === null || _iframeWindow$__FR_EN === void 0 ? void 0 : _iframeWindow$__FR_EN.init(_objectSpread({
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zzdadelu/schema-builder",
3
- "version": "1.0.0-alpha.90",
3
+ "version": "1.0.0-alpha.91",
4
4
  "description": "通过 JSON Schema 生成标准 Form,常用于自定义搭建配置界面生成",
5
5
  "keywords": [
6
6
  "Form",