File tree Expand file tree Collapse file tree 1 file changed +3
-2
lines changed
mystbin/frontend/components Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -14,6 +14,7 @@ import DropdownItem from "react-bootstrap/DropdownItem";
1414import React from "react" ;
1515import InsertPhotoIcon from "@material-ui/icons/InsertPhoto" ;
1616import SettingsIcon from '@material-ui/icons/Settings' ;
17+ import { language } from "@hapi/accept" ;
1718
1819const languages = {
1920 py : "python" ,
@@ -199,7 +200,7 @@ export default function EditorTabs({
199200 </ Button >
200201 { langDropDown ? (
201202 < div className = { styles . langParent } >
202- < Dropdown className = { styles . dropDown } autoClose >
203+ < Dropdown className = { styles . dropDown } autoClose = { 'outside' } >
203204 { Object . keys ( languages ) . map ( ( v , index ) => {
204205 if ( i !== currTab ) {
205206 return < > </ > ;
@@ -213,7 +214,7 @@ export default function EditorTabs({
213214 } }
214215 onClick = { ( ) => {
215216 setLangDropDown ( false ) ;
216- setDropLang ( v ) ;
217+ setDropLang ( getLanguage ( v ) ) ;
217218 } }
218219 >
219220 { v }
You can’t perform that action at this time.
0 commit comments