فهرست منبع

fix props destructuring in ShapeRepresentation3D

Alexander Rose 4 سال پیش
والد
کامیت
745f2aecf8
1فایلهای تغییر یافته به همراه1 افزوده شده و 1 حذف شده
  1. 1 1
      src/mol-plugin-state/transforms/representation.ts

+ 1 - 1
src/mol-plugin-state/transforms/representation.ts

@@ -679,7 +679,7 @@ const ShapeRepresentation3D = PluginStateTransform.BuiltIn({
     },
     apply({ a, params }, plugin: PluginContext) {
         return Task.create('Shape Representation', async ctx => {
-            const props = { ...PD.getDefaultValues(a.data.params), params };
+            const props = { ...PD.getDefaultValues(a.data.params), ...params };
             const repr = ShapeRepresentation(a.data.getShape, a.data.geometryUtils);
             // TODO set initial state, repr.setState({})
             await repr.createOrUpdate(props, a.data.data).runInContext(ctx);