{
  "meta": {
    "version": "4.000.9103",
    "fileFormatVersion": "0.4",
    "date": "2024-12-02T20:47:36.051Z",
    "name": "reset-counter",
    "description": "",
    "groupName": "",
    "tags": [],
    "schedulerLogOff": false
  },
  "data": {
    "datanodes": [
      {
        "name": "counter",
        "type": "JSON_formula_plugin",
        "settings": {
          "name": "counter",
          "autoStart": true,
          "explicitTrig": true,
          "json_var_formula": "return dataNodes[\"pastValue_counter\"]+1;\n"
        }
      },
      {
        "name": "pastValue_counter",
        "type": "Memory_plugin",
        "settings": {
          "name": "pastValue_counter",
          "value_init": "0",
          "datanode_origin": "counter"
        }
      },
      {
        "name": "reset",
        "type": "JSON_formula_plugin",
        "settings": {
          "name": "reset",
          "autoStart": false,
          "explicitTrig": true,
          "json_var_formula": "chalkit.setVariable(\"pastValue_counter\",0);\nchalkit.executeDataNode(\"counter\");\nreturn true;"
        }
      }
    ]
  },
  "libraries": {
    "pyodideStandard": [],
    "pyodideMicropip": []
  },
  "dashboard": {
    "flatUiValueDisplayA": {
      "layout": {
        "top": 96,
        "left": 101,
        "height": 39,
        "width": 290,
        "z-index": "2"
      },
      "container": {
        "instanceId": "flatUiValueDisplayA",
        "modelJsonId": "flatUiValueDisplay"
      },
      "modelParameters": {
        "label": "counter",
        "inheritLabelFromData": true,
        "displayLabel": true,
        "labelFontSize": 0.5,
        "labelColor": "var(--widget-label-color)",
        "labelFontFamily": "var(--widget-font-family)",
        "labelTextAlign": "left",
        "valueWidthProportion": "70%",
        "valueFontSize": 0.5,
        "valueColor": "var(--widget-input-text)",
        "valueFontFamily": "var(--widget-font-family)",
        "valueTextAlign": "left",
        "displayBorder": true,
        "borderColor": "var(--widget-border-color)",
        "backgroundColor": "var(--widget-input-color)",
        "unit": "unitText",
        "displayUnit": false,
        "unitFontSize": 0.5,
        "decimalDigits": 3,
        "borderWidth": "2px",
        "showWidget": true,
        "enableWidget": true
      },
      "modelHiddenParams": {
        "value": ""
      }
    },
    "flatUiButtonA": {
      "layout": {
        "top": 95,
        "left": 469,
        "height": 46,
        "width": 122,
        "z-index": "3"
      },
      "container": {
        "instanceId": "flatUiButtonA",
        "modelJsonId": "flatUiButton"
      },
      "modelParameters": {
        "text": "Add",
        "numberOfTriggers": 1,
        "fileInput": false,
        "binaryFileInput": false,
        "buttonFontSize": 0.3,
        "displayIcon": false,
        "fontAwesomeIcon": "",
        "buttonFontFamily": "var(--widget-font-family)",
        "buttonTextColor": "var(--widget-button-primary-text)",
        "buttonDefaultColor": "var(--widget-button-primary-color)",
        "buttonActiveColor": "var(--widget-button-active-color)",
        "buttonHoverColor": "var(--widget-button-hover-color)",
        "showWidget": true,
        "enableWidget": true
      },
      "modelHiddenParams": {}
    },
    "flatUiValueDisplayB": {
      "layout": {
        "top": 14,
        "left": 98,
        "height": 39,
        "width": 290,
        "z-index": "4"
      },
      "container": {
        "instanceId": "flatUiValueDisplayB",
        "modelJsonId": "flatUiValueDisplay"
      },
      "modelParameters": {
        "label": "pastValue_counter",
        "inheritLabelFromData": true,
        "displayLabel": true,
        "labelFontSize": 0.5,
        "labelColor": "var(--widget-label-color)",
        "labelFontFamily": "var(--widget-font-family)",
        "labelTextAlign": "left",
        "valueWidthProportion": "70%",
        "valueFontSize": 0.5,
        "valueColor": "var(--widget-input-text)",
        "valueFontFamily": "var(--widget-font-family)",
        "valueTextAlign": "left",
        "displayBorder": true,
        "borderColor": "var(--widget-border-color)",
        "backgroundColor": "var(--widget-input-color)",
        "unit": "unitText",
        "displayUnit": false,
        "unitFontSize": 0.5,
        "decimalDigits": 3,
        "borderWidth": "2px",
        "showWidget": true,
        "enableWidget": true
      },
      "modelHiddenParams": {
        "value": ""
      }
    },
    "flatUiButtonB": {
      "layout": {
        "top": 14,
        "left": 472,
        "height": 46,
        "width": 122,
        "z-index": "5"
      },
      "container": {
        "instanceId": "flatUiButtonB",
        "modelJsonId": "flatUiButton"
      },
      "modelParameters": {
        "text": "Reset",
        "numberOfTriggers": 1,
        "fileInput": false,
        "binaryFileInput": false,
        "buttonFontSize": 0.3,
        "displayIcon": false,
        "fontAwesomeIcon": "",
        "buttonFontFamily": "var(--widget-font-family)",
        "buttonTextColor": "var(--widget-button-primary-text)",
        "buttonDefaultColor": "var(--widget-button-primary-color)",
        "buttonActiveColor": "var(--widget-button-active-color)",
        "buttonHoverColor": "var(--widget-button-hover-color)",
        "showWidget": true,
        "enableWidget": true
      },
      "modelHiddenParams": {}
    },
    "annotationLabelA": {
      "layout": {
        "top": 51,
        "left": 205,
        "height": 39,
        "width": 183,
        "z-index": "6"
      },
      "container": {
        "instanceId": "annotationLabelA",
        "modelJsonId": "annotationLabel"
      },
      "modelParameters": {
        "text": "init_value == 0",
        "enableActuator": false,
        "fontsize": 0.5,
        "backgroundColor": "rgba(0, 0, 0, 0)",
        "textColor": "#07fcea",
        "valueFontFamily": "var(--widget-font-family)",
        "textAlign": "left",
        "textBold": false,
        "textUnderline": false,
        "textItalic": false,
        "displayBorder": false,
        "borderColor": "var(--widget-border-color)",
        "borderWidth": "2px",
        "centerVertically": true,
        "showWidget": true,
        "enableWidget": true
      },
      "modelHiddenParams": {}
    }
  },
  "connections": {
    "flatUiValueDisplayA": {
      "value": {
        "name": "value",
        "dataNode": "counter",
        "dataFields": []
      }
    },
    "flatUiButtonA": {
      "trigger1": {
        "name": "trigger1",
        "dataNode": "counter",
        "dataFields": []
      }
    },
    "flatUiValueDisplayB": {
      "value": {
        "name": "value",
        "dataNode": "pastValue_counter",
        "dataFields": []
      }
    },
    "flatUiButtonB": {
      "trigger1": {
        "name": "trigger1",
        "dataNode": "reset",
        "dataFields": []
      }
    },
    "annotationLabelA": {}
  },
  "display": {
    "theme": "default",
    "backgroundColor": "var(--widget-color-0)",
    "inheritThemeBackgroundColor": true,
    "marginX": 10,
    "marginY": 10,
    "width": 1294,
    "height": 590,
    "enforceHeightLimit": false
  },
  "navBarNotification": false
}