File tree Expand file tree Collapse file tree 3 files changed +11
-0
lines changed
Expand file tree Collapse file tree 3 files changed +11
-0
lines changed Original file line number Diff line number Diff line change @@ -236,6 +236,15 @@ $(function () {
236236 return ;
237237 }
238238
239+ const themeExists = Array . from ( $select . find ( 'option' ) ) . some ( ( opt ) => opt . value === name ) ;
240+ if ( themeExists ) {
241+ const confirmMessage = photoboothTools . getTranslation ( 'theme_override_confirm' ) . replace ( '%s' , name ) ;
242+ const confirmed = window . confirm ( confirmMessage ) ;
243+ if ( ! confirmed ) {
244+ return ;
245+ }
246+ }
247+
239248 const payload = {
240249 action : 'save' ,
241250 name : name ,
Original file line number Diff line number Diff line change 921921 "theme_load" : " Theme laden" ,
922922 "theme_delete" : " Theme löschen" ,
923923 "theme_choose" : " Theme auswählen" ,
924+ "theme_override_confirm" : " Theme \" %s\" wird überschrieben. Fortfahren?" ,
924925 "text_settings" : " Text-Einstellungen" ,
925926 "toggleFullscreen" : " Vollbildmodus umschalten" ,
926927 "translate" : " Übersetzen" ,
Original file line number Diff line number Diff line change 927927 "theme_load" : " Load theme" ,
928928 "theme_delete" : " Delete theme" ,
929929 "theme_choose" : " Choose theme" ,
930+ "theme_override_confirm" : " Saving will override theme \" %s\" . Continue?" ,
930931 "text_settings" : " Text settings" ,
931932 "toggleFullscreen" : " Toggle Fullscreen" ,
932933 "translate" : " Translate" ,
You can’t perform that action at this time.
0 commit comments