emacroh5lib 1.0.43 → 1.0.44

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "emacroh5lib",
3
- "version": "1.0.43",
3
+ "version": "1.0.44",
4
4
  "description": "EMacro前端组件库",
5
5
  "main": "dist/emacroh5lib.min.js",
6
6
  "scripts": {
@@ -285,11 +285,8 @@
285
285
 
286
286
  // Set style by name
287
287
  setStyleByName(obj, key, value) {
288
- try {
289
- obj && (obj.style[key] = value);
290
- } catch (error) {
291
- console.log("setStyleByName", error, obj, key, value);
292
- }
288
+ obj && (obj.style[key] = value);
289
+
293
290
  },
294
291
 
295
292
  // Get element current transform
@@ -333,11 +330,15 @@
333
330
 
334
331
  setTimeout(() => {
335
332
 
336
- this.setStyleByName(this.image, "width", this.currentData.width);
337
- this.setStyleByName(this.image, "height", this.currentData.height);
338
- this.setStyleByName(this.image, "left", this.currentData.left);
339
- this.setStyleByName(this.image, "top", this.currentData.top);
340
- this.setTransform(this.image, this.currentData.transform);
333
+ try {
334
+ this.setStyleByName(this.image, "width", this.currentData.width);
335
+ this.setStyleByName(this.image, "height", this.currentData.height);
336
+ this.setStyleByName(this.image, "left", this.currentData.left);
337
+ this.setStyleByName(this.image, "top", this.currentData.top);
338
+ this.setTransform(this.image, this.currentData.transform);
339
+ } catch (error) {
340
+ console.log("switchAction", error, this.image, this.currentData);
341
+ }
341
342
 
342
343
  this.resetZoom();
343
344
  this.resetPosition();