mirror of
https://gitcode.com/gh_mirrors/hy/Hydro.git
synced 2026-10-19 17:38:19 +08:00
core&ui: support set pretest to false
This commit is contained in:
1 parent
9afeae7047
commit
7df8e0c748
5 files changed
+8
-2
No files matched your search
@@ -99,6 +99,7 @@ export default connect(mapStateToProps, mapDispatchToProps)(class ScratchpadTool
|
||||
if (UiContext.pdoc.config?.type === 'remote_judge') {
|
||||
if (window.LANGS[this.props.editorLang].pretest) canUsePretest = true;
|
||||
}
|
||||
if (window.LANGS[this.props.editorLang].pretest === false) canUsePretest = false;
|
||||
return (
|
||||
<Toolbar>
|
||||
{canUsePretest && (
|
||||
|
||||
@@ -55,6 +55,10 @@ export default function reducer(state = {
|
||||
case 'SCRATCHPAD_POST_SUBMIT_PENDING': {
|
||||
return {
|
||||
...state,
|
||||
records: {
|
||||
...state.records,
|
||||
visible: true,
|
||||
},
|
||||
isPosting: true,
|
||||
};
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user