import e from"react";import{BsTrash as n,BsPencil as t}from"../../../../../../node_modules/react-icons/bs/index.esm.js";import{Icon as r}from"../../../../../../node_modules/@chakra-ui/icon/dist/esm/icon.js";export default function(a){var o=a.form,l=a.onRemoveField,i=a.onEditField,m=a.isEditing;return e.createElement(e.Fragment,null,e.createElement("div",{className:"form-generator-wrapper pt-4"},e.createElement("div",null,(o.fields||[]).map((function(a){return e.createElement("div",{key:a.id,className:"flex-column-structure form-generator-element mb-4"},e.createElement("div",{className:"flex-column-structure-child position-relative"},e.createElement("div",{className:"toolbar cursor-pointer"},e.createElement("div",{className:"d-flex flex-row"},e.createElement("div",{className:"toolbar-delete-icon"},e.createElement("span",{onClick:function(){return l(a)}},e.createElement(r,{as:n}))),e.createElement("div",{className:"toolbar-edit-icon "+(m?"d-none":"")},e.createElement("span",{onClick:function(){return i(a)}},e.createElement(r,{as:t}))))),e.createElement("div",{className:"pt-5 p-1"},e.createElement("div",{className:"form-field"}," Label : ",a.label," "),e.createElement("div",{className:"form-field"}," Type : ",a.type," "))))}))),e.createElement("style",{jsx:!0},"\n          .toolbar {\n            position: absolute;\n            top: 0;\n            left: 0;\n            width: 20%;\n            height: 35px;\n            background: #e8f0fe;\n            border-bottom-right-radius: 0.2rem;\n            border-top-left-radius: 0.2rem;\n            color: #1967d2;\n            padding: 0.2rem 0.8rem;\n          }\n\n          .toolbar-delete-icon {\n            margin-top: 3px;\n            margin-right: 1rem;\n          }\n\n          .toolbar-edit-icon {\n            margin-top: 3px;\n          }\n\n          .flex-column-structure-child {\n            border: 1px dashed #b3c4d6;\n          }\n\n          .flex-column-structure {\n            background: rgba(222, 228, 238, 0.3);\n          }\n        ")))}
//# sourceMappingURL=FormGeneratorElement.js.map
