mirror of
				https://github.com/yanislav-igonin/micrach
				synced 2025-11-04 10:27:02 +03:00 
			
		
		
		
	feat: header component
This commit is contained in:
		
							parent
							
								
									21c82b47e9
								
							
						
					
					
						commit
						2809a418a2
					
				
							
								
								
									
										17
									
								
								templates/header.html
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										17
									
								
								templates/header.html
									
									
									
									
									
										Normal file
									
								
							@ -0,0 +1,17 @@
 | 
				
			|||||||
 | 
					{{ define "header" }}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					{{ if . }}
 | 
				
			||||||
 | 
					<a href="/" class="thread-title-link">
 | 
				
			||||||
 | 
					  <h1 class="display-1 text-center thread-title">
 | 
				
			||||||
 | 
					    {{ if ne . "" }}
 | 
				
			||||||
 | 
					    {{ . }}
 | 
				
			||||||
 | 
					    {{ else }}
 | 
				
			||||||
 | 
					    Welcome to Micrach
 | 
				
			||||||
 | 
					    {{ end }}
 | 
				
			||||||
 | 
					  </h1>
 | 
				
			||||||
 | 
					</a>
 | 
				
			||||||
 | 
					{{ else }}
 | 
				
			||||||
 | 
					<h1 class="display-1 text-center">Welcome to Micrach</h1>
 | 
				
			||||||
 | 
					{{ end }}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					{{ end }}
 | 
				
			||||||
@ -8,7 +8,7 @@
 | 
				
			|||||||
</head>
 | 
					</head>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
<body>
 | 
					<body>
 | 
				
			||||||
  <h1 class="display-1 text-center">Welcome to Micrach</h1>
 | 
					  {{ template "header" }}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  <div class="container">
 | 
					  <div class="container">
 | 
				
			||||||
    {{ template "post-form" .FormData }}
 | 
					    {{ template "post-form" .FormData }}
 | 
				
			||||||
 | 
				
			|||||||
@ -11,15 +11,7 @@
 | 
				
			|||||||
</head>
 | 
					</head>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
<body>
 | 
					<body>
 | 
				
			||||||
  <a href="/" class="thread-title-link">
 | 
					  {{ template "header" $FirstPost.Title }}
 | 
				
			||||||
    <h1 class="display-1 text-center thread-title">
 | 
					 | 
				
			||||||
      {{ if ne $FirstPost.Title "" }}
 | 
					 | 
				
			||||||
      {{$FirstPost.Title}}
 | 
					 | 
				
			||||||
      {{ else }}
 | 
					 | 
				
			||||||
      Welcome to Micrach
 | 
					 | 
				
			||||||
      {{ end }}
 | 
					 | 
				
			||||||
    </h1>
 | 
					 | 
				
			||||||
  </a>
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
  <div class="container">
 | 
					  <div class="container">
 | 
				
			||||||
    {{ template "post-form" .FormData }}
 | 
					    {{ template "post-form" .FormData }}
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
		Reference in New Issue
	
	Block a user