Rework tab titles from "Album X" to "X | Albums" etc.
To prioritize the most unique and relevant piece of information.
This commit is contained in:
		
							parent
							
								
									df7fbeae0a
								
							
						
					
					
						commit
						50592f0ab4
					
				
					 3 changed files with 5 additions and 12 deletions
				
			
		|  | @ -4,7 +4,7 @@ | ||||||
|     {% import "photo_card.html" as photo_card %} |     {% import "photo_card.html" as photo_card %} | ||||||
|     {% import "header.html" as header %} |     {% import "header.html" as header %} | ||||||
|     {% import "clipboard_tray.html" as clipboard_tray %} |     {% import "clipboard_tray.html" as clipboard_tray %} | ||||||
|     <title>Album {{album.display_name}}</title> |     <title>{{album.display_name}} | Albums</title> | ||||||
|     <meta charset="UTF-8"> |     <meta charset="UTF-8"> | ||||||
|     <meta name="viewport" content="width=device-width, initial-scale=1.0"/> |     <meta name="viewport" content="width=device-width, initial-scale=1.0"/> | ||||||
|     <link rel="stylesheet" href="/static/css/common.css"> |     <link rel="stylesheet" href="/static/css/common.css"> | ||||||
|  | @ -179,14 +179,7 @@ function on_save(editor, edit_element_map, display_element_map) | ||||||
| 
 | 
 | ||||||
|         editor.hide_spinner(); |         editor.hide_spinner(); | ||||||
|         editor.save(); |         editor.save(); | ||||||
|         if (title_display.innerText == title_display.dataset.editorEmptyText) |         document.title = title_display.innerText + " | Albums"; | ||||||
|         { |  | ||||||
|             document.title = "Album " + title_display.dataset.editorEmptyText; |  | ||||||
|         } |  | ||||||
|         else |  | ||||||
|         { |  | ||||||
|             document.title = "Album " + title_display.innerText; |  | ||||||
|         } |  | ||||||
|         if (description_display.innerText == "") |         if (description_display.innerText == "") | ||||||
|         { |         { | ||||||
|             description_display.classList.add("hidden"); |             description_display.classList.add("hidden"); | ||||||
|  |  | ||||||
|  | @ -3,7 +3,7 @@ | ||||||
| <head> | <head> | ||||||
|     {% import "header.html" as header %} |     {% import "header.html" as header %} | ||||||
|     {% import "tag_object.html" as tag_object %} |     {% import "tag_object.html" as tag_object %} | ||||||
|     <title>Photo {{photo.basename}}</title> |     <title>{{photo.basename}} | Photos</title> | ||||||
|     <meta charset="UTF-8"> |     <meta charset="UTF-8"> | ||||||
|     <meta name="viewport" content="width=device-width, initial-scale=1.0"/> |     <meta name="viewport" content="width=device-width, initial-scale=1.0"/> | ||||||
|     <link rel="stylesheet" href="/static/css/common.css"> |     <link rel="stylesheet" href="/static/css/common.css"> | ||||||
|  |  | ||||||
|  | @ -6,7 +6,7 @@ | ||||||
|     {% if specific_tag is none %} |     {% if specific_tag is none %} | ||||||
|         <title>Tags</title> |         <title>Tags</title> | ||||||
|     {% else %} |     {% else %} | ||||||
|         <title>Tag {{specific_tag.name}}</title> |         <title>{{specific_tag.name}} | Tags</title> | ||||||
|     {% endif %} |     {% endif %} | ||||||
|     <meta charset="UTF-8"> |     <meta charset="UTF-8"> | ||||||
|     <meta name="viewport" content="width=device-width, initial-scale=1.0"/> |     <meta name="viewport" content="width=device-width, initial-scale=1.0"/> | ||||||
|  | @ -252,7 +252,7 @@ function on_save(editor, edit_element_map, display_element_map) | ||||||
|         { |         { | ||||||
|             var new_name = response["data"]["name"]; |             var new_name = response["data"]["name"]; | ||||||
|             var new_description = response["data"]["description"]; |             var new_description = response["data"]["description"]; | ||||||
|             document.title = "Tag " + new_name; |             document.title = new_name + " | Tags"; | ||||||
|             window.history.replaceState(null, null, "/tag/" + new_name); |             window.history.replaceState(null, null, "/tag/" + new_name); | ||||||
|             name_editor.value = new_name; |             name_editor.value = new_name; | ||||||
|             description_editor.value = new_description; |             description_editor.value = new_description; | ||||||
|  |  | ||||||
		Loading…
	
		Reference in a new issue