@@ -5,6 +5,7 @@ import { css, html, LitElement, nothing } from 'lit';
55import { customElement , state } from 'lit/decorators.js' ;
66import { ifDefined } from 'lit/directives/if-defined.js' ;
77import { isSubscriptionTrialOrPaidFromState } from '../../../../../plus/gk/utils/subscription.utils' ;
8+ import type { AssociateIssueWithBranchCommandArgs } from '../../../../../plus/startWork/startWork' ;
89import { createCommandLink } from '../../../../../system/commands' ;
910import { createWebviewCommandLink } from '../../../../../system/webview' ;
1011import type {
@@ -231,6 +232,11 @@ export class GlActiveBranchCard extends GlBranchCardBase {
231232 flex-direction: column;
232233 gap: 0.8rem;
233234 }
235+
236+ span.branch-item__missing {
237+ color: var(--vscode-descriptionForeground);
238+ font-style: italic;
239+ }
234240 ` ,
235241 ] ;
236242
@@ -511,4 +517,30 @@ export class GlActiveBranchCard extends GlBranchCardBase {
511517 protected getCollapsedActions ( ) : TemplateResult [ ] {
512518 return [ ] ;
513519 }
520+
521+ protected override renderIssuesItem ( ) : TemplateResult | NothingType {
522+ const issues = [ ...( this . issues ?? [ ] ) , ...( this . autolinks ?? [ ] ) ] ;
523+ if ( ! issues . length ) {
524+ if ( ! this . expanded ) return nothing ;
525+
526+ return html `< div class ="branch-item__row " full >
527+ < span class ="branch-item__missing " full > Current work item</ span >
528+ < gl-tooltip hoist content ="Associate an issue ">
529+ < a
530+ href =${ this . createCommandLink < AssociateIssueWithBranchCommandArgs > (
531+ 'gitlens.associateIssueWithBranch' ,
532+ {
533+ branch : this . branch . reference ,
534+ source : 'home' ,
535+ } ,
536+ ) }
537+ > < span class ="branch-item__icon "> < issue-icon > </ issue-icon > </ span
538+ > </ a >
539+ </ gl-tooltip >
540+ </ div > ` ;
541+ }
542+ return super . renderIssuesItem ( ) ;
543+ }
514544}
545+
546+ type NothingType = typeof nothing ;
0 commit comments