@arquimedes.co/eureka-forms 1.9.57-test → 1.9.58-test

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.
@@ -2,6 +2,7 @@ export interface GBaseStep {
2
2
  id: string;
3
3
  type: string;
4
4
  editable?: boolean;
5
+ partial?: boolean;
5
6
  dependencies?: string[];
6
7
  }
7
8
  export interface GTitle extends GBaseStep {
@@ -20,13 +20,12 @@ var __rest = (this && this.__rest) || function (s, e) {
20
20
  }
21
21
  return t;
22
22
  };
23
- import { createElement as _createElement } from "react";
24
23
  import { jsx as _jsx } from "react/jsx-runtime";
24
+ import { createElement as _createElement } from "react";
25
25
  import StepComponent from '../../Step/Step';
26
26
  import styles from './MaterialSection.module.css';
27
27
  function MaterialSection(_a) {
28
28
  var form = _a.form, section = _a.section, widthStats = _a.widthStats, sendLabel = _a.sendLabel, others = __rest(_a, ["form", "section", "widthStats", "sendLabel"]);
29
- var postview = others.postview, partial = others.partial, originalValues = others.originalValues;
30
29
  return (_jsx("div", __assign({ className: styles.container, style: {
31
30
  width: (form.size.blockSize + form.size.spacingSize) *
32
31
  form.size.blockNum,
@@ -37,12 +36,7 @@ function MaterialSection(_a) {
37
36
  } }, { children: section.steps.map(function (idStep) {
38
37
  var step = form.steps[idStep];
39
38
  //If partial is active only display steps with originalValues
40
- if (postview &&
41
- partial &&
42
- originalValues[idStep] === undefined) {
43
- return _jsx("div", {}, idStep);
44
- }
45
- else if (step) {
39
+ if (step) {
46
40
  return (_createElement(StepComponent, __assign({}, others, { globalEditable: others.editable, widthStats: widthStats, form: form, step: step, key: idStep, level: 0 })));
47
41
  }
48
42
  else {
@@ -45,6 +45,11 @@ function StepComponent(_a) {
45
45
  if (customStep) {
46
46
  return customStep.component(__assign(__assign(__assign({}, props), ((_c = customStep.componentProps) !== null && _c !== void 0 ? _c : {})), { step: step, editable: editable }));
47
47
  }
48
+ if ((props.postview || !editable) &&
49
+ (props.partial || step.partial) &&
50
+ props.originalValues[step.id] === undefined) {
51
+ return _jsx("div", {});
52
+ }
48
53
  switch (step.type) {
49
54
  case Types.TITLE: {
50
55
  return (_jsx(TitleStep, __assign({}, props, { step: step, editable: editable })));
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@arquimedes.co/eureka-forms",
3
3
  "repository": "git://github.com/Arquimede5/Eureka-Forms.git",
4
- "version":"1.9.57-test",
4
+ "version":"1.9.58-test",
5
5
  "scripts": {
6
6
  "start": "react-scripts start",
7
7
  "build": "react-scripts build",