"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e,r,n,i,t,s,d=require("../../_virtual/_rollupPluginBabelHelpers.js"),o=require("react"),a=require("../../node_modules/@uiw/react-codemirror/esm/index.js"),l=require("../../node_modules/@codemirror/lang-javascript/dist/index.js"),u=require("../../node_modules/@codemirror/lang-sql/dist/index.js"),c=require("../../node_modules/@codemirror/lang-java/dist/index.js"),m=require("../../node_modules/@codemirror/lang-python/dist/index.js"),p=require("../../node_modules/@codemirror/lang-html/dist/index.js"),x=require("../../node_modules/@codemirror/lang-css/dist/index.js"),g=require("../../node_modules/@codemirror/lang-cpp/dist/index.js"),j=require("../../node_modules/@codemirror/lang-json/dist/index.js"),h=require("../../node_modules/@codemirror/lang-xml/dist/index.js"),v=require("../../node_modules/@codemirror/lang-markdown/dist/index.js"),q=require("styled-components"),f=require("../../_virtual/index.js"),_=require("react/jsx-runtime");function b(e){var r=e.codeType,n=e.onChange,i=e.value,t=e.theme,s=e.label,q=e.required,f=e.name,b=o.useState(!1),B=d.slicedToArray(b,2);B[0];var C=B[1];return _.jsx(y,{children:_.jsxs(T,{tabIndex:"0",onFocus:function(){C(!0)},onBlur:function(){C(!1)},children:[_.jsxs(w,{children:[_.jsxs(L,{children:[s,q&&"*"]}),_.jsx(k,{children:r})]}),_.jsx(P,{children:_.jsx(a.default,{value:i,onChange:function(e){n({target:{name:f,value:e}})},extensions:function(){switch(r){case"javascript":return[l.javascript()];case"sql":return[u.sql()];case"java":return[c.java()];case"python":return[m.python()];case"html":return[p.html()];case"css":return[x.css()];case"cpp":return[g.cpp()];case"json":return[j.json()];case"xml":return[h.xml()];case"markdown":return[v.markdown()];default:return[]}}(),theme:t||"light"})})]})})}b.PropTypes={codeType:f.default.oneOf(["javascript","sql","java","python","html","css","cpp","json","xml","markdown"])};var y=q.div(e||(e=d.taggedTemplateLiteral(["\n  min-height: 54px;\n  border: 1px solid rgb(202, 202, 202);\n  border-radius: 5px;\n  display: flex;\n  align-items: center;\n  /* justify-content: center; */\n  /* text-align: center; */\n  cursor: pointer;\n  transition: background 0.3s ease;\n  color: rgb(102, 102, 102);\n\n  &:hover {\n    border-color: rgb(33, 33, 33);\n  }\n\n  &:focus-within {\n    border: 2px solid rgb(25, 118, 210);\n  }\n"]))),T=q.div(r||(r=d.taggedTemplateLiteral(["\n  width: 100%;\n"]))),w=q.div(n||(n=d.taggedTemplateLiteral(["\n  display: flex;\n  flex-direction: row;\n"]))),L=q.div(i||(i=d.taggedTemplateLiteral(["\n  display: flex;\n  margin-left: 13px;\n  flex: 1;\n"]))),k=q.div(t||(t=d.taggedTemplateLiteral(["\n  margin-right: 13px;\n  font-size: 15px;\n"]))),P=q.div(s||(s=d.taggedTemplateLiteral(["\n  margin-bottom: 5px;\n"])));exports.default=b;
//# sourceMappingURL=CodeInputComponent.js.map
