File tree Expand file tree Collapse file tree 3 files changed +6
-0
lines changed
indigo_app/static/javascript/indigo/views Expand file tree Collapse file tree 3 files changed +6
-0
lines changed Original file line number Diff line number Diff line change 67
67
} ,
68
68
69
69
removeTerms : function ( e ) {
70
+ if ( ! Indigo . view . sourceEditorView . confirmAndDiscardChanges ( ) ) return ;
71
+
70
72
// unwrap all <def>s
71
73
this . model . xmlDocument . querySelectorAll ( 'def' ) . forEach ( function ( def ) {
72
74
var parent = def . parentNode ;
Original file line number Diff line number Diff line change 67
67
} ,
68
68
69
69
removeItalics : function ( e ) {
70
+ if ( ! Indigo . view . sourceEditorView . confirmAndDiscardChanges ( ) ) return ;
71
+
70
72
// remove all italics mark-up
71
73
this . $ ( 'a[href="#this-document-italics-terms"]' ) . click ( ) ;
72
74
Original file line number Diff line number Diff line change 80
80
} ,
81
81
82
82
removeReferences : function ( e ) {
83
+ if ( ! Indigo . view . sourceEditorView . confirmAndDiscardChanges ( ) ) return ;
84
+
83
85
// remove all non-absolute refs
84
86
this . model . xmlDocument . querySelectorAll ( 'ref' ) . forEach ( function ( ref ) {
85
87
if ( ( ref . getAttribute ( 'href' ) || "" ) . startsWith ( '/' ) || ( ref . getAttribute ( 'href' ) || "" ) . startsWith ( '#' ) ) {
You can’t perform that action at this time.
0 commit comments