@@ -40,6 +40,8 @@ const ICON_SUN = `<svg xmlns="http://www.w3.org/2000/svg" width="18" height="18"
4040
4141const ICON_MOON = `<svg xmlns="http://www.w3.org/2000/svg" width="18" height="18" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M12 3a6 6 0 0 0 9 9 9 9 0 1 1-9-9Z"/></svg>` ;
4242
43+ const ICON_EXTERNAL = `<svg xmlns="http://www.w3.org/2000/svg" width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M7 7h10v10"/><path d="M7 17 17 7"/></svg>` ;
44+
4345const TOGGLE_SCRIPT = `
4446function toggleTheme() {
4547 const root = document.documentElement;
@@ -176,27 +178,27 @@ function rfcPage(rfc: RFC, repoUrl: string | null, liveReload: boolean = false):
176178
177179 // Accepted date
178180 if ( rfc . git . accepted ) {
179- const acceptedLink = repoUrl
180- ? `<a href="${ repoUrl } /commit/${ rfc . git . accepted . hash } " class="commit-link">${ formatDate ( rfc . git . accepted . date ) } </a>`
181- : formatDate ( rfc . git . accepted . date ) ;
181+ const commitLink = repoUrl
182+ ? ` <a href="${ repoUrl } /commit/${ rfc . git . accepted . hash } " class="commit-link" title="View commit" >${ ICON_EXTERNAL } </a>`
183+ : "" ;
182184
183185 gitHeader += `
184186 <div class="rfc-meta-item">
185187 <span class="rfc-meta-label">Accepted:</span>
186- ${ acceptedLink }
188+ <span class="rfc-meta-value"> ${ formatDate ( rfc . git . accepted . date ) } ${ commitLink } </span>
187189 </div>` ;
188190 }
189191
190192 // Last updated date
191193 if ( rfc . git . lastUpdated ) {
192- const updatedLink = repoUrl
193- ? `<a href="${ repoUrl } /commit/${ rfc . git . lastUpdated . hash } " class="commit-link">${ formatDate ( rfc . git . lastUpdated . date ) } </a>`
194- : formatDate ( rfc . git . lastUpdated . date ) ;
194+ const commitLink = repoUrl
195+ ? ` <a href="${ repoUrl } /commit/${ rfc . git . lastUpdated . hash } " class="commit-link" title="View commit" >${ ICON_EXTERNAL } </a>`
196+ : "" ;
195197
196198 gitHeader += `
197199 <div class="rfc-meta-item">
198200 <span class="rfc-meta-label">Last updated:</span>
199- ${ updatedLink }
201+ <span class="rfc-meta-value"> ${ formatDate ( rfc . git . lastUpdated . date ) } ${ commitLink } </span>
200202 </div>` ;
201203 }
202204
0 commit comments