File tree Expand file tree Collapse file tree 5 files changed +1
-67
lines changed Expand file tree Collapse file tree 5 files changed +1
-67
lines changed Original file line number Diff line number Diff line change @@ -171,18 +171,6 @@ export function closeShareModal() {
171171 } ;
172172}
173173
174- export function showEditorOptions ( ) {
175- return {
176- type : ActionTypes . SHOW_EDITOR_OPTIONS
177- } ;
178- }
179-
180- export function closeEditorOptions ( ) {
181- return {
182- type : ActionTypes . CLOSE_EDITOR_OPTIONS
183- } ;
184- }
185-
186174export function showKeyboardShortcutModal ( ) {
187175 return {
188176 type : ActionTypes . SHOW_KEYBOARD_SHORTCUT_MODAL
Original file line number Diff line number Diff line change @@ -362,20 +362,10 @@ class Editor extends React.Component {
362362 } ) ;
363363 }
364364
365- toggleEditorOptions ( ) {
366- if ( this . props . editorOptionsVisible ) {
367- this . props . closeEditorOptions ( ) ;
368- } else {
369- this . optionsButton . focus ( ) ;
370- this . props . showEditorOptions ( ) ;
371- }
372- }
373-
374365 render ( ) {
375366 const editorSectionClass = classNames ( {
376367 editor : true ,
377- 'sidebar--contracted' : ! this . props . isExpanded ,
378- 'editor--options' : this . props . editorOptionsVisible
368+ 'sidebar--contracted' : ! this . props . isExpanded
379369 } ) ;
380370
381371 const editorHolderClass = classNames ( {
@@ -462,9 +452,6 @@ Editor.propTypes = {
462452 fileType : PropTypes . string . isRequired ,
463453 url : PropTypes . string
464454 } ) . isRequired ,
465- editorOptionsVisible : PropTypes . bool . isRequired ,
466- showEditorOptions : PropTypes . func . isRequired ,
467- closeEditorOptions : PropTypes . func . isRequired ,
468455 setUnsavedChanges : PropTypes . func . isRequired ,
469456 startRefreshSketch : PropTypes . func . isRequired ,
470457 autorefresh : PropTypes . bool . isRequired ,
Original file line number Diff line number Diff line change @@ -14,7 +14,6 @@ const initialState = {
1414 shareModalProjectId : 'abcd' ,
1515 shareModalProjectName : 'My Cute Sketch' ,
1616 shareModalProjectUsername : 'p5_user' ,
17- editorOptionsVisible : false ,
1817 keyboardShortcutVisible : false ,
1918 unsavedChanges : false ,
2019 infiniteLoop : false ,
@@ -82,10 +81,6 @@ const ide = (state = initialState, action) => {
8281 } ) ;
8382 case ActionTypes . CLOSE_SHARE_MODAL :
8483 return Object . assign ( { } , state , { shareModalVisible : false } ) ;
85- case ActionTypes . SHOW_EDITOR_OPTIONS :
86- return Object . assign ( { } , state , { editorOptionsVisible : true } ) ;
87- case ActionTypes . CLOSE_EDITOR_OPTIONS :
88- return Object . assign ( { } , state , { editorOptionsVisible : false } ) ;
8984 case ActionTypes . SHOW_KEYBOARD_SHORTCUT_MODAL :
9085 return Object . assign ( { } , state , { keyboardShortcutVisible : true } ) ;
9186 case ActionTypes . CLOSE_KEYBOARD_SHORTCUT_MODAL :
Original file line number Diff line number Diff line change @@ -372,41 +372,6 @@ pre.CodeMirror-line {
372372 height : #{29 / $base-font-size } rem;
373373}
374374
375- .editor__options-button {
376- @include icon ();
377- position : absolute ;
378- top : #{10 / $base-font-size } rem;
379- right : #{2 / $base-font-size } rem;
380- z-index : 1 ;
381- }
382-
383-
384- .editor__options {
385- display : none ;
386- @extend %modal ;
387- position : absolute ;
388- right : #{0 / $base-font-size } rem;
389- padding : #{8 / $base-font-size } rem #{20 / $base-font-size } rem;
390- font-size : #{12 / $base-font-size } rem;
391- @include themify () {
392- background-color : getThemifyVariable (' modal-background-color' );
393- box-shadow : 0 0 18px getThemifyVariable (' shadow-color' );
394- }
395- .editor--options & {
396- display : block ;
397- }
398- }
399-
400- .editor__options li {
401- padding : #{4 / $base-font-size } rem 0 ;
402- }
403-
404- .editor__options a {
405- @include themify () {
406- color : getThemifyVariable (' secondary-text-color' );
407- }
408- }
409-
410375.editor__file-name {
411376 @include themify () {
412377 color : getThemifyVariable (' primary-text-color' );
Original file line number Diff line number Diff line change @@ -32,7 +32,6 @@ const initialTestState = {
3232 shareModalProjectId : 'abcd' ,
3333 shareModalProjectName : 'My Cute Sketch' ,
3434 shareModalProjectUsername : 'p5_user' ,
35- editorOptionsVisible : false ,
3635 keyboardShortcutVisible : false ,
3736 unsavedChanges : false ,
3837 infiniteLoop : false ,
You can’t perform that action at this time.
0 commit comments