fix(web): reopen diff files on a layout switch and let x expand them again
- commit
- 5e5d8fbe2752b45a31f22547f931af6c206f0559
- author
- brice · · 2026-10-11 12:46 UTC
- parent
- e84f160
- signature
- GPG Verified
CD88F9E564E0102646FB6077A1A07C7C7C3E349D· arch-gpg Verified for the committer email
8 files · +319 -268
M internal/adapters/web/diff.templ +9 -1
| @@ -55,7 +55,7 @@ templ Commit(l Layout, p CommitPage) { | |||
| 55 | 55 | <span class="grow"></span> | |
| 56 | 56 | @viewLink(p.DiffView, "unified", "Unified", "u", p.UnifiedHref) | |
| 57 | 57 | @viewLink(p.DiffView, "split", "Split", "d", p.SplitHref) | |
| 58 | - | <button type="button" aria-keyshortcuts="x" hx-on:click="document.body.dispatchEvent(new CustomEvent('k-collapse'))" class="btn">Collapse all<kbd aria-hidden="true">x</kbd></button> | |
| 58 | + | @collapseButton() | |
| 59 | 59 | </div> | |
| 60 | 60 | if p.Invisible { | |
| 61 | 61 | <p class="notice"> | |
| @@ -112,6 +112,14 @@ templ viewLink(p DiffView, view, label, key, href string) { | |||
| 112 | 112 | >{ label }<kbd aria-hidden="true">{ key }</kbd></a> | |
| 113 | 113 | } | |
| 114 | 114 | ||
| 115 | + | // collapseButton folds every file of the diff, or opens them all again when | |
| 116 | + | // none is open; its label follows the state. | |
| 117 | + | templ collapseButton() { | |
| 118 | + | <button type="button" aria-keyshortcuts="x" hx-on:click="document.body.dispatchEvent(new CustomEvent('k-collapse'))" class="btn"> | |
| 119 | + | <span hx-live="this.textContent = q('[data-file][open]').count || !q('[data-file]').count ? 'Collapse all' : 'Expand all'">Collapse all</span><kbd aria-hidden="true">x</kbd> | |
| 120 | + | </button> | |
| 121 | + | } | |
| 122 | + | ||
| 115 | 123 | templ personView(pr Person) { | |
| 116 | 124 | { pr.Name } | |
| 117 | 125 | if pr.WhenAt != "" { | |
| @@ -55,7 +55,7 @@ templ Commit(l Layout, p CommitPage) { | |||||
| 55 | <span class="grow"></span> | 55 | <span class="grow"></span> | ||
| 56 | @viewLink(p.DiffView, "unified", "Unified", "u", p.UnifiedHref) | 56 | @viewLink(p.DiffView, "unified", "Unified", "u", p.UnifiedHref) | ||
| 57 | @viewLink(p.DiffView, "split", "Split", "d", p.SplitHref) | 57 | @viewLink(p.DiffView, "split", "Split", "d", p.SplitHref) | ||
| 58 | - | <button type="button" aria-keyshortcuts="x" hx-on:click="document.body.dispatchEvent(new CustomEvent('k-collapse'))" class="btn">Collapse all<kbd aria-hidden="true">x</kbd></button> | 58 | + | @collapseButton() |
| 59 | </div> | 59 | </div> | ||
| 60 | if p.Invisible { | 60 | if p.Invisible { | ||
| 61 | <p class="notice"> | 61 | <p class="notice"> | ||
| @@ -112,6 +112,14 @@ templ viewLink(p DiffView, view, label, key, href string) { | |||||
| 112 | >{ label }<kbd aria-hidden="true">{ key }</kbd></a> | 112 | >{ label }<kbd aria-hidden="true">{ key }</kbd></a> | ||
| 113 | } | 113 | } | ||
| 114 | 114 | ||||
| 115 | + | // collapseButton folds every file of the diff, or opens them all again when | |||
| 116 | + | // none is open; its label follows the state. | |||
| 117 | + | templ collapseButton() { | |||
| 118 | + | <button type="button" aria-keyshortcuts="x" hx-on:click="document.body.dispatchEvent(new CustomEvent('k-collapse'))" class="btn"> | |||
| 119 | + | <span hx-live="this.textContent = q('[data-file][open]').count || !q('[data-file]').count ? 'Collapse all' : 'Expand all'">Collapse all</span><kbd aria-hidden="true">x</kbd> | |||
| 120 | + | </button> | |||
| 121 | + | } | |||
| 122 | + | ||||
| 115 | templ personView(pr Person) { | 123 | templ personView(pr Person) { | ||
| 116 | { pr.Name } | 124 | { pr.Name } | ||
| 117 | if pr.WhenAt != "" { | 125 | if pr.WhenAt != "" { | ||
M internal/adapters/web/diff_templ.go +292 -257
| @@ -282,7 +282,11 @@ func Commit(l Layout, p CommitPage) templ.Component { | |||
| 282 | 282 | if templ_7745c5c3_Err != nil { | |
| 283 | 283 | return templ_7745c5c3_Err | |
| 284 | 284 | } | |
| 285 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 27, "<button type=\"button\" aria-keyshortcuts=\"x\" hx-on:click=\"document.body.dispatchEvent(new CustomEvent('k-collapse'))\" class=\"btn\">Collapse all<kbd aria-hidden=\"true\">x</kbd></button></div>") | |
| 285 | + | templ_7745c5c3_Err = collapseButton().Render(ctx, templ_7745c5c3_Buffer) | |
| 286 | + | if templ_7745c5c3_Err != nil { | |
| 287 | + | return templ_7745c5c3_Err | |
| 288 | + | } | |
| 289 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 27, "</div>") | |
| 286 | 290 | if templ_7745c5c3_Err != nil { | |
| 287 | 291 | return templ_7745c5c3_Err | |
| 288 | 292 | } | |
| @@ -546,7 +550,9 @@ func viewLink(p DiffView, view, label, key, href string) templ.Component { | |||
| 546 | 550 | }) | |
| 547 | 551 | } | |
| 548 | 552 | ||
| 549 | - | func personView(pr Person) templ.Component { | |
| 553 | + | // collapseButton folds every file of the diff, or opens them all again when | |
| 554 | + | // none is open; its label follows the state. | |
| 555 | + | func collapseButton() templ.Component { | |
| 550 | 556 | return templruntime.GeneratedTemplate(func(templ_7745c5c3_Input templruntime.GeneratedComponentInput) (templ_7745c5c3_Err error) { | |
| 551 | 557 | templ_7745c5c3_W, ctx := templ_7745c5c3_Input.Writer, templ_7745c5c3_Input.Context | |
| 552 | 558 | if templ_7745c5c3_CtxErr := ctx.Err(); templ_7745c5c3_CtxErr != nil { | |
| @@ -567,78 +573,107 @@ func personView(pr Person) templ.Component { | |||
| 567 | 573 | templ_7745c5c3_Var25 = templ.NopComponent | |
| 568 | 574 | } | |
| 569 | 575 | ctx = templ.ClearChildren(ctx) | |
| 570 | - | var templ_7745c5c3_Var26 string | |
| 571 | - | templ_7745c5c3_Var26, templ_7745c5c3_Err = templ.JoinStringErrs(pr.Name) | |
| 576 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 55, "<button type=\"button\" aria-keyshortcuts=\"x\" hx-on:click=\"document.body.dispatchEvent(new CustomEvent('k-collapse'))\" class=\"btn\"><span hx-live=\"this.textContent = q('[data-file][open]').count || !q('[data-file]').count ? 'Collapse all' : 'Expand all'\">Collapse all</span><kbd aria-hidden=\"true\">x</kbd></button>") | |
| 577 | + | if templ_7745c5c3_Err != nil { | |
| 578 | + | return templ_7745c5c3_Err | |
| 579 | + | } | |
| 580 | + | return nil | |
| 581 | + | }) | |
| 582 | + | } | |
| 583 | + | ||
| 584 | + | func personView(pr Person) templ.Component { | |
| 585 | + | return templruntime.GeneratedTemplate(func(templ_7745c5c3_Input templruntime.GeneratedComponentInput) (templ_7745c5c3_Err error) { | |
| 586 | + | templ_7745c5c3_W, ctx := templ_7745c5c3_Input.Writer, templ_7745c5c3_Input.Context | |
| 587 | + | if templ_7745c5c3_CtxErr := ctx.Err(); templ_7745c5c3_CtxErr != nil { | |
| 588 | + | return templ_7745c5c3_CtxErr | |
| 589 | + | } | |
| 590 | + | templ_7745c5c3_Buffer, templ_7745c5c3_IsBuffer := templruntime.GetBuffer(templ_7745c5c3_W) | |
| 591 | + | if !templ_7745c5c3_IsBuffer { | |
| 592 | + | defer func() { | |
| 593 | + | templ_7745c5c3_BufErr := templruntime.ReleaseBuffer(templ_7745c5c3_Buffer) | |
| 594 | + | if templ_7745c5c3_Err == nil { | |
| 595 | + | templ_7745c5c3_Err = templ_7745c5c3_BufErr | |
| 596 | + | } | |
| 597 | + | }() | |
| 598 | + | } | |
| 599 | + | ctx = templ.InitializeContext(ctx) | |
| 600 | + | templ_7745c5c3_Var26 := templ.GetChildren(ctx) | |
| 601 | + | if templ_7745c5c3_Var26 == nil { | |
| 602 | + | templ_7745c5c3_Var26 = templ.NopComponent | |
| 603 | + | } | |
| 604 | + | ctx = templ.ClearChildren(ctx) | |
| 605 | + | var templ_7745c5c3_Var27 string | |
| 606 | + | templ_7745c5c3_Var27, templ_7745c5c3_Err = templ.JoinStringErrs(pr.Name) | |
| 572 | 607 | if templ_7745c5c3_Err != nil { | |
| 573 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 116, Col: 10} | |
| 608 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 124, Col: 10} | |
| 574 | 609 | } | |
| 575 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var26)) | |
| 610 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var27)) | |
| 576 | 611 | if templ_7745c5c3_Err != nil { | |
| 577 | 612 | return templ_7745c5c3_Err | |
| 578 | 613 | } | |
| 579 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 55, " ") | |
| 614 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 56, " ") | |
| 580 | 615 | if templ_7745c5c3_Err != nil { | |
| 581 | 616 | return templ_7745c5c3_Err | |
| 582 | 617 | } | |
| 583 | 618 | if pr.WhenAt != "" { | |
| 584 | - | var templ_7745c5c3_Var27 string | |
| 585 | - | templ_7745c5c3_Var27, templ_7745c5c3_Err = templ.JoinStringErrs(" · ") | |
| 619 | + | var templ_7745c5c3_Var28 string | |
| 620 | + | templ_7745c5c3_Var28, templ_7745c5c3_Err = templ.JoinStringErrs(" · ") | |
| 586 | 621 | if templ_7745c5c3_Err != nil { | |
| 587 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 118, Col: 10} | |
| 622 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 126, Col: 10} | |
| 588 | 623 | } | |
| 589 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var27)) | |
| 624 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var28)) | |
| 590 | 625 | if templ_7745c5c3_Err != nil { | |
| 591 | 626 | return templ_7745c5c3_Err | |
| 592 | 627 | } | |
| 593 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 56, "<time datetime=\"") | |
| 628 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 57, "<time datetime=\"") | |
| 594 | 629 | if templ_7745c5c3_Err != nil { | |
| 595 | 630 | return templ_7745c5c3_Err | |
| 596 | 631 | } | |
| 597 | - | var templ_7745c5c3_Var28 string | |
| 598 | - | templ_7745c5c3_Var28, templ_7745c5c3_Err = templ.ResolveAttributeValue(pr.WhenAt) | |
| 632 | + | var templ_7745c5c3_Var29 string | |
| 633 | + | templ_7745c5c3_Var29, templ_7745c5c3_Err = templ.ResolveAttributeValue(pr.WhenAt) | |
| 599 | 634 | if templ_7745c5c3_Err != nil { | |
| 600 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 118, Col: 38} | |
| 635 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 126, Col: 38} | |
| 601 | 636 | } | |
| 602 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var28) | |
| 637 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var29) | |
| 603 | 638 | if templ_7745c5c3_Err != nil { | |
| 604 | 639 | return templ_7745c5c3_Err | |
| 605 | 640 | } | |
| 606 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 57, "\" title=\"") | |
| 641 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 58, "\" title=\"") | |
| 607 | 642 | if templ_7745c5c3_Err != nil { | |
| 608 | 643 | return templ_7745c5c3_Err | |
| 609 | 644 | } | |
| 610 | - | var templ_7745c5c3_Var29 string | |
| 611 | - | templ_7745c5c3_Var29, templ_7745c5c3_Err = templ.ResolveAttributeValue(pr.Abs) | |
| 645 | + | var templ_7745c5c3_Var30 string | |
| 646 | + | templ_7745c5c3_Var30, templ_7745c5c3_Err = templ.ResolveAttributeValue(pr.Abs) | |
| 612 | 647 | if templ_7745c5c3_Err != nil { | |
| 613 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 118, Col: 55} | |
| 648 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 126, Col: 55} | |
| 614 | 649 | } | |
| 615 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var29) | |
| 650 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var30) | |
| 616 | 651 | if templ_7745c5c3_Err != nil { | |
| 617 | 652 | return templ_7745c5c3_Err | |
| 618 | 653 | } | |
| 619 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 58, "\">") | |
| 654 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 59, "\">") | |
| 620 | 655 | if templ_7745c5c3_Err != nil { | |
| 621 | 656 | return templ_7745c5c3_Err | |
| 622 | 657 | } | |
| 623 | - | var templ_7745c5c3_Var30 string | |
| 624 | - | templ_7745c5c3_Var30, templ_7745c5c3_Err = templ.JoinStringErrs(pr.When) | |
| 658 | + | var templ_7745c5c3_Var31 string | |
| 659 | + | templ_7745c5c3_Var31, templ_7745c5c3_Err = templ.JoinStringErrs(pr.When) | |
| 625 | 660 | if templ_7745c5c3_Err != nil { | |
| 626 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 118, Col: 67} | |
| 661 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 126, Col: 67} | |
| 627 | 662 | } | |
| 628 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var30)) | |
| 663 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var31)) | |
| 629 | 664 | if templ_7745c5c3_Err != nil { | |
| 630 | 665 | return templ_7745c5c3_Err | |
| 631 | 666 | } | |
| 632 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 59, "</time>") | |
| 667 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 60, "</time>") | |
| 633 | 668 | if templ_7745c5c3_Err != nil { | |
| 634 | 669 | return templ_7745c5c3_Err | |
| 635 | 670 | } | |
| 636 | - | var templ_7745c5c3_Var31 string | |
| 637 | - | templ_7745c5c3_Var31, templ_7745c5c3_Err = templ.JoinStringErrs(" · " + pr.Abs) | |
| 671 | + | var templ_7745c5c3_Var32 string | |
| 672 | + | templ_7745c5c3_Var32, templ_7745c5c3_Err = templ.JoinStringErrs(" · " + pr.Abs) | |
| 638 | 673 | if templ_7745c5c3_Err != nil { | |
| 639 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 118, Col: 93} | |
| 674 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 126, Col: 93} | |
| 640 | 675 | } | |
| 641 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var31)) | |
| 676 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var32)) | |
| 642 | 677 | if templ_7745c5c3_Err != nil { | |
| 643 | 678 | return templ_7745c5c3_Err | |
| 644 | 679 | } | |
| @@ -663,25 +698,25 @@ func commitRail(p CommitPage) templ.Component { | |||
| 663 | 698 | }() | |
| 664 | 699 | } | |
| 665 | 700 | ctx = templ.InitializeContext(ctx) | |
| 666 | - | templ_7745c5c3_Var32 := templ.GetChildren(ctx) | |
| 667 | - | if templ_7745c5c3_Var32 == nil { | |
| 668 | - | templ_7745c5c3_Var32 = templ.NopComponent | |
| 701 | + | templ_7745c5c3_Var33 := templ.GetChildren(ctx) | |
| 702 | + | if templ_7745c5c3_Var33 == nil { | |
| 703 | + | templ_7745c5c3_Var33 = templ.NopComponent | |
| 669 | 704 | } | |
| 670 | 705 | ctx = templ.ClearChildren(ctx) | |
| 671 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 60, "<section aria-labelledby=\"r-files\"><h2 id=\"r-files\">Files <span class=\"count\">") | |
| 706 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 61, "<section aria-labelledby=\"r-files\"><h2 id=\"r-files\">Files <span class=\"count\">") | |
| 672 | 707 | if templ_7745c5c3_Err != nil { | |
| 673 | 708 | return templ_7745c5c3_Err | |
| 674 | 709 | } | |
| 675 | - | var templ_7745c5c3_Var33 string | |
| 676 | - | templ_7745c5c3_Var33, templ_7745c5c3_Err = templ.JoinStringErrs(itoa(len(p.Files))) | |
| 710 | + | var templ_7745c5c3_Var34 string | |
| 711 | + | templ_7745c5c3_Var34, templ_7745c5c3_Err = templ.JoinStringErrs(itoa(len(p.Files))) | |
| 677 | 712 | if templ_7745c5c3_Err != nil { | |
| 678 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 124, Col: 65} | |
| 713 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 132, Col: 65} | |
| 679 | 714 | } | |
| 680 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var33)) | |
| 715 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var34)) | |
| 681 | 716 | if templ_7745c5c3_Err != nil { | |
| 682 | 717 | return templ_7745c5c3_Err | |
| 683 | 718 | } | |
| 684 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 61, "</span></h2>") | |
| 719 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 62, "</span></h2>") | |
| 685 | 720 | if templ_7745c5c3_Err != nil { | |
| 686 | 721 | return templ_7745c5c3_Err | |
| 687 | 722 | } | |
| @@ -689,7 +724,7 @@ func commitRail(p CommitPage) templ.Component { | |||
| 689 | 724 | if templ_7745c5c3_Err != nil { | |
| 690 | 725 | return templ_7745c5c3_Err | |
| 691 | 726 | } | |
| 692 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 62, "</section>") | |
| 727 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 63, "</section>") | |
| 693 | 728 | if templ_7745c5c3_Err != nil { | |
| 694 | 729 | return templ_7745c5c3_Err | |
| 695 | 730 | } | |
| @@ -715,165 +750,165 @@ func FileList(files []DiffFile) templ.Component { | |||
| 715 | 750 | }() | |
| 716 | 751 | } | |
| 717 | 752 | ctx = templ.InitializeContext(ctx) | |
| 718 | - | templ_7745c5c3_Var34 := templ.GetChildren(ctx) | |
| 719 | - | if templ_7745c5c3_Var34 == nil { | |
| 720 | - | templ_7745c5c3_Var34 = templ.NopComponent | |
| 753 | + | templ_7745c5c3_Var35 := templ.GetChildren(ctx) | |
| 754 | + | if templ_7745c5c3_Var35 == nil { | |
| 755 | + | templ_7745c5c3_Var35 = templ.NopComponent | |
| 721 | 756 | } | |
| 722 | 757 | ctx = templ.ClearChildren(ctx) | |
| 723 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 63, "<ol class=\"files\" aria-label=\"Changed files\">") | |
| 758 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 64, "<ol class=\"files\" aria-label=\"Changed files\">") | |
| 724 | 759 | if templ_7745c5c3_Err != nil { | |
| 725 | 760 | return templ_7745c5c3_Err | |
| 726 | 761 | } | |
| 727 | 762 | for _, f := range files { | |
| 728 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 64, "<li><a href=\"") | |
| 763 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 65, "<li><a href=\"") | |
| 729 | 764 | if templ_7745c5c3_Err != nil { | |
| 730 | 765 | return templ_7745c5c3_Err | |
| 731 | 766 | } | |
| 732 | - | var templ_7745c5c3_Var35 templ.SafeURL | |
| 733 | - | templ_7745c5c3_Var35, templ_7745c5c3_Err = templ.JoinURLErrs(templ.SafeURL("#" + f.ID)) | |
| 767 | + | var templ_7745c5c3_Var36 templ.SafeURL | |
| 768 | + | templ_7745c5c3_Var36, templ_7745c5c3_Err = templ.JoinURLErrs(templ.SafeURL("#" + f.ID)) | |
| 734 | 769 | if templ_7745c5c3_Err != nil { | |
| 735 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 136, Col: 37} | |
| 770 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 144, Col: 37} | |
| 736 | 771 | } | |
| 737 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var35)) | |
| 772 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var36)) | |
| 738 | 773 | if templ_7745c5c3_Err != nil { | |
| 739 | 774 | return templ_7745c5c3_Err | |
| 740 | 775 | } | |
| 741 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 65, "\" :aria-current=\"") | |
| 742 | - | if templ_7745c5c3_Err != nil { | |
| 743 | - | return templ_7745c5c3_Err | |
| 744 | - | } | |
| 745 | - | var templ_7745c5c3_Var36 string | |
| 746 | - | templ_7745c5c3_Var36, templ_7745c5c3_Err = templ.ResolveAttributeValue("(() => { let all = q('.dfile').arr(); let cur = all.filter(f => f.getBoundingClientRect().top < innerHeight / 3).at(-1) || all[0]; return cur?.id === '" + f.ID + "' ? 'true' : false })()") | |
| 747 | - | if templ_7745c5c3_Err != nil { | |
| 748 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 137, Col: 209} | |
| 749 | - | } | |
| 750 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var36) | |
| 751 | - | if templ_7745c5c3_Err != nil { | |
| 752 | - | return templ_7745c5c3_Err | |
| 753 | - | } | |
| 754 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 66, "\" hx-on:click=\"document.getElementById(this.hash.slice(1)).open = true\"><span class=\"st\" title=\"") | |
| 776 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 66, "\" :aria-current=\"") | |
| 755 | 777 | if templ_7745c5c3_Err != nil { | |
| 756 | 778 | return templ_7745c5c3_Err | |
| 757 | 779 | } | |
| 758 | 780 | var templ_7745c5c3_Var37 string | |
| 759 | - | templ_7745c5c3_Var37, templ_7745c5c3_Err = templ.ResolveAttributeValue(f.Status) | |
| 781 | + | templ_7745c5c3_Var37, templ_7745c5c3_Err = templ.ResolveAttributeValue("(() => { let all = q('.dfile').arr(); let cur = all.filter(f => f.getBoundingClientRect().top < innerHeight / 3).at(-1) || all[0]; return cur?.id === '" + f.ID + "' ? 'true' : false })()") | |
| 760 | 782 | if templ_7745c5c3_Err != nil { | |
| 761 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 140, Col: 38} | |
| 783 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 145, Col: 209} | |
| 762 | 784 | } | |
| 763 | 785 | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var37) | |
| 764 | 786 | if templ_7745c5c3_Err != nil { | |
| 765 | 787 | return templ_7745c5c3_Err | |
| 766 | 788 | } | |
| 767 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 67, "\">") | |
| 789 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 67, "\" hx-on:click=\"document.getElementById(this.hash.slice(1)).open = true\"><span class=\"st\" title=\"") | |
| 768 | 790 | if templ_7745c5c3_Err != nil { | |
| 769 | 791 | return templ_7745c5c3_Err | |
| 770 | 792 | } | |
| 771 | 793 | var templ_7745c5c3_Var38 string | |
| 772 | - | templ_7745c5c3_Var38, templ_7745c5c3_Err = templ.JoinStringErrs(f.Status) | |
| 794 | + | templ_7745c5c3_Var38, templ_7745c5c3_Err = templ.ResolveAttributeValue(f.Status) | |
| 773 | 795 | if templ_7745c5c3_Err != nil { | |
| 774 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 140, Col: 51} | |
| 796 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 148, Col: 38} | |
| 775 | 797 | } | |
| 776 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var38)) | |
| 798 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var38) | |
| 777 | 799 | if templ_7745c5c3_Err != nil { | |
| 778 | 800 | return templ_7745c5c3_Err | |
| 779 | 801 | } | |
| 780 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 68, "</span> <span class=\"p\" title=\"") | |
| 802 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 68, "\">") | |
| 781 | 803 | if templ_7745c5c3_Err != nil { | |
| 782 | 804 | return templ_7745c5c3_Err | |
| 783 | 805 | } | |
| 784 | 806 | var templ_7745c5c3_Var39 string | |
| 785 | - | templ_7745c5c3_Var39, templ_7745c5c3_Err = templ.ResolveAttributeValue(f.Path) | |
| 807 | + | templ_7745c5c3_Var39, templ_7745c5c3_Err = templ.JoinStringErrs(f.Status) | |
| 786 | 808 | if templ_7745c5c3_Err != nil { | |
| 787 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 141, Col: 35} | |
| 809 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 148, Col: 51} | |
| 788 | 810 | } | |
| 789 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var39) | |
| 811 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var39)) | |
| 790 | 812 | if templ_7745c5c3_Err != nil { | |
| 791 | 813 | return templ_7745c5c3_Err | |
| 792 | 814 | } | |
| 793 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 69, "\">") | |
| 815 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 69, "</span> <span class=\"p\" title=\"") | |
| 794 | 816 | if templ_7745c5c3_Err != nil { | |
| 795 | 817 | return templ_7745c5c3_Err | |
| 796 | 818 | } | |
| 797 | 819 | var templ_7745c5c3_Var40 string | |
| 798 | - | templ_7745c5c3_Var40, templ_7745c5c3_Err = templ.JoinStringErrs(f.Path) | |
| 820 | + | templ_7745c5c3_Var40, templ_7745c5c3_Err = templ.ResolveAttributeValue(f.Path) | |
| 799 | 821 | if templ_7745c5c3_Err != nil { | |
| 800 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 141, Col: 46} | |
| 822 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 149, Col: 35} | |
| 801 | 823 | } | |
| 802 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var40)) | |
| 824 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var40) | |
| 803 | 825 | if templ_7745c5c3_Err != nil { | |
| 804 | 826 | return templ_7745c5c3_Err | |
| 805 | 827 | } | |
| 806 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 70, "</span> <span class=\"n\"><span class=\"plus\">+") | |
| 828 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 70, "\">") | |
| 807 | 829 | if templ_7745c5c3_Err != nil { | |
| 808 | 830 | return templ_7745c5c3_Err | |
| 809 | 831 | } | |
| 810 | 832 | var templ_7745c5c3_Var41 string | |
| 811 | - | templ_7745c5c3_Var41, templ_7745c5c3_Err = templ.JoinStringErrs(itoa(f.Add)) | |
| 833 | + | templ_7745c5c3_Var41, templ_7745c5c3_Err = templ.JoinStringErrs(f.Path) | |
| 812 | 834 | if templ_7745c5c3_Err != nil { | |
| 813 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 142, Col: 54} | |
| 835 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 149, Col: 46} | |
| 814 | 836 | } | |
| 815 | 837 | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var41)) | |
| 816 | 838 | if templ_7745c5c3_Err != nil { | |
| 817 | 839 | return templ_7745c5c3_Err | |
| 818 | 840 | } | |
| 819 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 71, "</span> <span class=\"minus\">-") | |
| 841 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 71, "</span> <span class=\"n\"><span class=\"plus\">+") | |
| 820 | 842 | if templ_7745c5c3_Err != nil { | |
| 821 | 843 | return templ_7745c5c3_Err | |
| 822 | 844 | } | |
| 823 | 845 | var templ_7745c5c3_Var42 string | |
| 824 | - | templ_7745c5c3_Var42, templ_7745c5c3_Err = templ.JoinStringErrs(itoa(f.Del)) | |
| 846 | + | templ_7745c5c3_Var42, templ_7745c5c3_Err = templ.JoinStringErrs(itoa(f.Add)) | |
| 825 | 847 | if templ_7745c5c3_Err != nil { | |
| 826 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 142, Col: 98} | |
| 848 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 150, Col: 54} | |
| 827 | 849 | } | |
| 828 | 850 | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var42)) | |
| 829 | 851 | if templ_7745c5c3_Err != nil { | |
| 830 | 852 | return templ_7745c5c3_Err | |
| 831 | 853 | } | |
| 832 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 72, "</span></span> <span class=\"b\" aria-hidden=\"true\"><span class=\"plus\">") | |
| 854 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 72, "</span> <span class=\"minus\">-") | |
| 833 | 855 | if templ_7745c5c3_Err != nil { | |
| 834 | 856 | return templ_7745c5c3_Err | |
| 835 | 857 | } | |
| 836 | 858 | var templ_7745c5c3_Var43 string | |
| 837 | - | templ_7745c5c3_Var43, templ_7745c5c3_Err = templ.JoinStringErrs(f.Bar.Add) | |
| 859 | + | templ_7745c5c3_Var43, templ_7745c5c3_Err = templ.JoinStringErrs(itoa(f.Del)) | |
| 838 | 860 | if templ_7745c5c3_Err != nil { | |
| 839 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 143, Col: 70} | |
| 861 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 150, Col: 98} | |
| 840 | 862 | } | |
| 841 | 863 | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var43)) | |
| 842 | 864 | if templ_7745c5c3_Err != nil { | |
| 843 | 865 | return templ_7745c5c3_Err | |
| 844 | 866 | } | |
| 845 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 73, "</span><span class=\"minus\">") | |
| 867 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 73, "</span></span> <span class=\"b\" aria-hidden=\"true\"><span class=\"plus\">") | |
| 846 | 868 | if templ_7745c5c3_Err != nil { | |
| 847 | 869 | return templ_7745c5c3_Err | |
| 848 | 870 | } | |
| 849 | 871 | var templ_7745c5c3_Var44 string | |
| 850 | - | templ_7745c5c3_Var44, templ_7745c5c3_Err = templ.JoinStringErrs(f.Bar.Del) | |
| 872 | + | templ_7745c5c3_Var44, templ_7745c5c3_Err = templ.JoinStringErrs(f.Bar.Add) | |
| 851 | 873 | if templ_7745c5c3_Err != nil { | |
| 852 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 143, Col: 110} | |
| 874 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 151, Col: 70} | |
| 853 | 875 | } | |
| 854 | 876 | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var44)) | |
| 855 | 877 | if templ_7745c5c3_Err != nil { | |
| 856 | 878 | return templ_7745c5c3_Err | |
| 857 | 879 | } | |
| 858 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 74, "</span>") | |
| 880 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 74, "</span><span class=\"minus\">") | |
| 859 | 881 | if templ_7745c5c3_Err != nil { | |
| 860 | 882 | return templ_7745c5c3_Err | |
| 861 | 883 | } | |
| 862 | 884 | var templ_7745c5c3_Var45 string | |
| 863 | - | templ_7745c5c3_Var45, templ_7745c5c3_Err = templ.JoinStringErrs(f.Bar.Rest) | |
| 885 | + | templ_7745c5c3_Var45, templ_7745c5c3_Err = templ.JoinStringErrs(f.Bar.Del) | |
| 864 | 886 | if templ_7745c5c3_Err != nil { | |
| 865 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 143, Col: 131} | |
| 887 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 151, Col: 110} | |
| 866 | 888 | } | |
| 867 | 889 | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var45)) | |
| 868 | 890 | if templ_7745c5c3_Err != nil { | |
| 869 | 891 | return templ_7745c5c3_Err | |
| 870 | 892 | } | |
| 871 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 75, "</span></a></li>") | |
| 893 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 75, "</span>") | |
| 894 | + | if templ_7745c5c3_Err != nil { | |
| 895 | + | return templ_7745c5c3_Err | |
| 896 | + | } | |
| 897 | + | var templ_7745c5c3_Var46 string | |
| 898 | + | templ_7745c5c3_Var46, templ_7745c5c3_Err = templ.JoinStringErrs(f.Bar.Rest) | |
| 899 | + | if templ_7745c5c3_Err != nil { | |
| 900 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 151, Col: 131} | |
| 901 | + | } | |
| 902 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var46)) | |
| 903 | + | if templ_7745c5c3_Err != nil { | |
| 904 | + | return templ_7745c5c3_Err | |
| 905 | + | } | |
| 906 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 76, "</span></a></li>") | |
| 872 | 907 | if templ_7745c5c3_Err != nil { | |
| 873 | 908 | return templ_7745c5c3_Err | |
| 874 | 909 | } | |
| 875 | 910 | } | |
| 876 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 76, "</ol>") | |
| 911 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 77, "</ol>") | |
| 877 | 912 | if templ_7745c5c3_Err != nil { | |
| 878 | 913 | return templ_7745c5c3_Err | |
| 879 | 914 | } | |
| @@ -901,222 +936,222 @@ func DiffFileView(f DiffFile, p DiffView) templ.Component { | |||
| 901 | 936 | }() | |
| 902 | 937 | } | |
| 903 | 938 | ctx = templ.InitializeContext(ctx) | |
| 904 | - | templ_7745c5c3_Var46 := templ.GetChildren(ctx) | |
| 905 | - | if templ_7745c5c3_Var46 == nil { | |
| 906 | - | templ_7745c5c3_Var46 = templ.NopComponent | |
| 939 | + | templ_7745c5c3_Var47 := templ.GetChildren(ctx) | |
| 940 | + | if templ_7745c5c3_Var47 == nil { | |
| 941 | + | templ_7745c5c3_Var47 = templ.NopComponent | |
| 907 | 942 | } | |
| 908 | 943 | ctx = templ.ClearChildren(ctx) | |
| 909 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 77, "<details class=\"dfile\" id=\"") | |
| 944 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 78, "<details class=\"dfile\" id=\"") | |
| 910 | 945 | if templ_7745c5c3_Err != nil { | |
| 911 | 946 | return templ_7745c5c3_Err | |
| 912 | 947 | } | |
| 913 | - | var templ_7745c5c3_Var47 string | |
| 914 | - | templ_7745c5c3_Var47, templ_7745c5c3_Err = templ.ResolveAttributeValue(f.ID) | |
| 948 | + | var templ_7745c5c3_Var48 string | |
| 949 | + | templ_7745c5c3_Var48, templ_7745c5c3_Err = templ.ResolveAttributeValue(f.ID) | |
| 915 | 950 | if templ_7745c5c3_Err != nil { | |
| 916 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 157, Col: 11} | |
| 951 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 165, Col: 11} | |
| 917 | 952 | } | |
| 918 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var47) | |
| 953 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var48) | |
| 919 | 954 | if templ_7745c5c3_Err != nil { | |
| 920 | 955 | return templ_7745c5c3_Err | |
| 921 | 956 | } | |
| 922 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 78, "\" data-file") | |
| 957 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 79, "\" data-file") | |
| 923 | 958 | if templ_7745c5c3_Err != nil { | |
| 924 | 959 | return templ_7745c5c3_Err | |
| 925 | 960 | } | |
| 926 | 961 | if f.Open { | |
| 927 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 79, " open") | |
| 962 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 80, " open") | |
| 928 | 963 | if templ_7745c5c3_Err != nil { | |
| 929 | 964 | return templ_7745c5c3_Err | |
| 930 | 965 | } | |
| 931 | 966 | } | |
| 932 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 80, "><summary><span class=\"st\">") | |
| 933 | - | if templ_7745c5c3_Err != nil { | |
| 934 | - | return templ_7745c5c3_Err | |
| 935 | - | } | |
| 936 | - | var templ_7745c5c3_Var48 string | |
| 937 | - | templ_7745c5c3_Var48, templ_7745c5c3_Err = templ.JoinStringErrs(f.Status) | |
| 938 | - | if templ_7745c5c3_Err != nil { | |
| 939 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 164, Col: 30} | |
| 940 | - | } | |
| 941 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var48)) | |
| 942 | - | if templ_7745c5c3_Err != nil { | |
| 943 | - | return templ_7745c5c3_Err | |
| 944 | - | } | |
| 945 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 81, "</span>") | |
| 967 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 81, "><summary><span class=\"st\">") | |
| 946 | 968 | if templ_7745c5c3_Err != nil { | |
| 947 | 969 | return templ_7745c5c3_Err | |
| 948 | 970 | } | |
| 949 | 971 | var templ_7745c5c3_Var49 string | |
| 950 | - | templ_7745c5c3_Var49, templ_7745c5c3_Err = templ.JoinStringErrs(" ") | |
| 972 | + | templ_7745c5c3_Var49, templ_7745c5c3_Err = templ.JoinStringErrs(f.Status) | |
| 951 | 973 | if templ_7745c5c3_Err != nil { | |
| 952 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 164, Col: 44} | |
| 974 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 172, Col: 30} | |
| 953 | 975 | } | |
| 954 | 976 | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var49)) | |
| 955 | 977 | if templ_7745c5c3_Err != nil { | |
| 956 | 978 | return templ_7745c5c3_Err | |
| 957 | 979 | } | |
| 958 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 82, "<span class=\"p\">") | |
| 980 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 82, "</span>") | |
| 959 | 981 | if templ_7745c5c3_Err != nil { | |
| 960 | 982 | return templ_7745c5c3_Err | |
| 961 | 983 | } | |
| 962 | 984 | var templ_7745c5c3_Var50 string | |
| 963 | - | templ_7745c5c3_Var50, templ_7745c5c3_Err = templ.JoinStringErrs(f.Path) | |
| 985 | + | templ_7745c5c3_Var50, templ_7745c5c3_Err = templ.JoinStringErrs(" ") | |
| 964 | 986 | if templ_7745c5c3_Err != nil { | |
| 965 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 164, Col: 70} | |
| 987 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 172, Col: 44} | |
| 966 | 988 | } | |
| 967 | 989 | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var50)) | |
| 968 | 990 | if templ_7745c5c3_Err != nil { | |
| 969 | 991 | return templ_7745c5c3_Err | |
| 970 | 992 | } | |
| 971 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 83, "</span>") | |
| 993 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 83, "<span class=\"p\">") | |
| 972 | 994 | if templ_7745c5c3_Err != nil { | |
| 973 | 995 | return templ_7745c5c3_Err | |
| 974 | 996 | } | |
| 975 | 997 | var templ_7745c5c3_Var51 string | |
| 976 | - | templ_7745c5c3_Var51, templ_7745c5c3_Err = templ.JoinStringErrs(" ") | |
| 998 | + | templ_7745c5c3_Var51, templ_7745c5c3_Err = templ.JoinStringErrs(f.Path) | |
| 977 | 999 | if templ_7745c5c3_Err != nil { | |
| 978 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 164, Col: 84} | |
| 1000 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 172, Col: 70} | |
| 979 | 1001 | } | |
| 980 | 1002 | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var51)) | |
| 981 | 1003 | if templ_7745c5c3_Err != nil { | |
| 982 | 1004 | return templ_7745c5c3_Err | |
| 983 | 1005 | } | |
| 984 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 84, "<span class=\"plus\">+") | |
| 1006 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 84, "</span>") | |
| 985 | 1007 | if templ_7745c5c3_Err != nil { | |
| 986 | 1008 | return templ_7745c5c3_Err | |
| 987 | 1009 | } | |
| 988 | 1010 | var templ_7745c5c3_Var52 string | |
| 989 | - | templ_7745c5c3_Var52, templ_7745c5c3_Err = templ.JoinStringErrs(itoa(f.Add)) | |
| 1011 | + | templ_7745c5c3_Var52, templ_7745c5c3_Err = templ.JoinStringErrs(" ") | |
| 990 | 1012 | if templ_7745c5c3_Err != nil { | |
| 991 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 164, Col: 119} | |
| 1013 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 172, Col: 84} | |
| 992 | 1014 | } | |
| 993 | 1015 | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var52)) | |
| 994 | 1016 | if templ_7745c5c3_Err != nil { | |
| 995 | 1017 | return templ_7745c5c3_Err | |
| 996 | 1018 | } | |
| 997 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 85, "</span>") | |
| 1019 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 85, "<span class=\"plus\">+") | |
| 998 | 1020 | if templ_7745c5c3_Err != nil { | |
| 999 | 1021 | return templ_7745c5c3_Err | |
| 1000 | 1022 | } | |
| 1001 | 1023 | var templ_7745c5c3_Var53 string | |
| 1002 | - | templ_7745c5c3_Var53, templ_7745c5c3_Err = templ.JoinStringErrs(" ") | |
| 1024 | + | templ_7745c5c3_Var53, templ_7745c5c3_Err = templ.JoinStringErrs(itoa(f.Add)) | |
| 1003 | 1025 | if templ_7745c5c3_Err != nil { | |
| 1004 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 164, Col: 133} | |
| 1026 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 172, Col: 119} | |
| 1005 | 1027 | } | |
| 1006 | 1028 | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var53)) | |
| 1007 | 1029 | if templ_7745c5c3_Err != nil { | |
| 1008 | 1030 | return templ_7745c5c3_Err | |
| 1009 | 1031 | } | |
| 1010 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 86, "<span class=\"minus\">-") | |
| 1032 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 86, "</span>") | |
| 1011 | 1033 | if templ_7745c5c3_Err != nil { | |
| 1012 | 1034 | return templ_7745c5c3_Err | |
| 1013 | 1035 | } | |
| 1014 | 1036 | var templ_7745c5c3_Var54 string | |
| 1015 | - | templ_7745c5c3_Var54, templ_7745c5c3_Err = templ.JoinStringErrs(itoa(f.Del)) | |
| 1037 | + | templ_7745c5c3_Var54, templ_7745c5c3_Err = templ.JoinStringErrs(" ") | |
| 1016 | 1038 | if templ_7745c5c3_Err != nil { | |
| 1017 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 164, Col: 169} | |
| 1039 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 172, Col: 133} | |
| 1018 | 1040 | } | |
| 1019 | 1041 | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var54)) | |
| 1020 | 1042 | if templ_7745c5c3_Err != nil { | |
| 1021 | 1043 | return templ_7745c5c3_Err | |
| 1022 | 1044 | } | |
| 1023 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 87, "</span> ") | |
| 1045 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 87, "<span class=\"minus\">-") | |
| 1046 | + | if templ_7745c5c3_Err != nil { | |
| 1047 | + | return templ_7745c5c3_Err | |
| 1048 | + | } | |
| 1049 | + | var templ_7745c5c3_Var55 string | |
| 1050 | + | templ_7745c5c3_Var55, templ_7745c5c3_Err = templ.JoinStringErrs(itoa(f.Del)) | |
| 1051 | + | if templ_7745c5c3_Err != nil { | |
| 1052 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 172, Col: 169} | |
| 1053 | + | } | |
| 1054 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var55)) | |
| 1055 | + | if templ_7745c5c3_Err != nil { | |
| 1056 | + | return templ_7745c5c3_Err | |
| 1057 | + | } | |
| 1058 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 88, "</span> ") | |
| 1024 | 1059 | if templ_7745c5c3_Err != nil { | |
| 1025 | 1060 | return templ_7745c5c3_Err | |
| 1026 | 1061 | } | |
| 1027 | 1062 | if f.Note != "" { | |
| 1028 | - | var templ_7745c5c3_Var55 string | |
| 1029 | - | templ_7745c5c3_Var55, templ_7745c5c3_Err = templ.JoinStringErrs(" ") | |
| 1063 | + | var templ_7745c5c3_Var56 string | |
| 1064 | + | templ_7745c5c3_Var56, templ_7745c5c3_Err = templ.JoinStringErrs(" ") | |
| 1030 | 1065 | if templ_7745c5c3_Err != nil { | |
| 1031 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 166, Col: 9} | |
| 1066 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 174, Col: 9} | |
| 1032 | 1067 | } | |
| 1033 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var55)) | |
| 1068 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var56)) | |
| 1034 | 1069 | if templ_7745c5c3_Err != nil { | |
| 1035 | 1070 | return templ_7745c5c3_Err | |
| 1036 | 1071 | } | |
| 1037 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 88, "<span class=\"note\">") | |
| 1072 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 89, "<span class=\"note\">") | |
| 1038 | 1073 | if templ_7745c5c3_Err != nil { | |
| 1039 | 1074 | return templ_7745c5c3_Err | |
| 1040 | 1075 | } | |
| 1041 | - | var templ_7745c5c3_Var56 string | |
| 1042 | - | templ_7745c5c3_Var56, templ_7745c5c3_Err = templ.JoinStringErrs(f.Note) | |
| 1076 | + | var templ_7745c5c3_Var57 string | |
| 1077 | + | templ_7745c5c3_Var57, templ_7745c5c3_Err = templ.JoinStringErrs(f.Note) | |
| 1043 | 1078 | if templ_7745c5c3_Err != nil { | |
| 1044 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 166, Col: 38} | |
| 1079 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 174, Col: 38} | |
| 1045 | 1080 | } | |
| 1046 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var56)) | |
| 1081 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var57)) | |
| 1047 | 1082 | if templ_7745c5c3_Err != nil { | |
| 1048 | 1083 | return templ_7745c5c3_Err | |
| 1049 | 1084 | } | |
| 1050 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 89, "</span>") | |
| 1085 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 90, "</span>") | |
| 1051 | 1086 | if templ_7745c5c3_Err != nil { | |
| 1052 | 1087 | return templ_7745c5c3_Err | |
| 1053 | 1088 | } | |
| 1054 | 1089 | } | |
| 1055 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 90, "</summary> ") | |
| 1090 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 91, "</summary> ") | |
| 1056 | 1091 | if templ_7745c5c3_Err != nil { | |
| 1057 | 1092 | return templ_7745c5c3_Err | |
| 1058 | 1093 | } | |
| 1059 | 1094 | if len(f.Hunks) > 0 { | |
| 1060 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 91, "<div class=\"dscroll\">") | |
| 1095 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 92, "<div class=\"dscroll\">") | |
| 1061 | 1096 | if templ_7745c5c3_Err != nil { | |
| 1062 | 1097 | return templ_7745c5c3_Err | |
| 1063 | 1098 | } | |
| 1064 | 1099 | if p.ShowUnified { | |
| 1065 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 92, "<table class=\"dt uni\" aria-label=\"") | |
| 1100 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 93, "<table class=\"dt uni\" aria-label=\"") | |
| 1066 | 1101 | if templ_7745c5c3_Err != nil { | |
| 1067 | 1102 | return templ_7745c5c3_Err | |
| 1068 | 1103 | } | |
| 1069 | - | var templ_7745c5c3_Var57 string | |
| 1070 | - | templ_7745c5c3_Var57, templ_7745c5c3_Err = templ.ResolveAttributeValue(f.Path + ", unified") | |
| 1104 | + | var templ_7745c5c3_Var58 string | |
| 1105 | + | templ_7745c5c3_Var58, templ_7745c5c3_Err = templ.ResolveAttributeValue(f.Path + ", unified") | |
| 1071 | 1106 | if templ_7745c5c3_Err != nil { | |
| 1072 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 172, Col: 60} | |
| 1107 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 180, Col: 60} | |
| 1073 | 1108 | } | |
| 1074 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var57) | |
| 1109 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var58) | |
| 1075 | 1110 | if templ_7745c5c3_Err != nil { | |
| 1076 | 1111 | return templ_7745c5c3_Err | |
| 1077 | 1112 | } | |
| 1078 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 93, "\">") | |
| 1113 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 94, "\">") | |
| 1079 | 1114 | if templ_7745c5c3_Err != nil { | |
| 1080 | 1115 | return templ_7745c5c3_Err | |
| 1081 | 1116 | } | |
| 1082 | 1117 | for _, h := range f.Hunks { | |
| 1083 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 94, "<tbody><tr class=\"hunk\"><td colspan=\"4\">") | |
| 1118 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 95, "<tbody><tr class=\"hunk\"><td colspan=\"4\">") | |
| 1084 | 1119 | if templ_7745c5c3_Err != nil { | |
| 1085 | 1120 | return templ_7745c5c3_Err | |
| 1086 | 1121 | } | |
| 1087 | - | var templ_7745c5c3_Var58 string | |
| 1088 | - | templ_7745c5c3_Var58, templ_7745c5c3_Err = templ.JoinStringErrs(h.Header) | |
| 1122 | + | var templ_7745c5c3_Var59 string | |
| 1123 | + | templ_7745c5c3_Var59, templ_7745c5c3_Err = templ.JoinStringErrs(h.Header) | |
| 1089 | 1124 | if templ_7745c5c3_Err != nil { | |
| 1090 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 175, Col: 51} | |
| 1125 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 183, Col: 51} | |
| 1091 | 1126 | } | |
| 1092 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var58)) | |
| 1127 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var59)) | |
| 1093 | 1128 | if templ_7745c5c3_Err != nil { | |
| 1094 | 1129 | return templ_7745c5c3_Err | |
| 1095 | 1130 | } | |
| 1096 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 95, "</td></tr>") | |
| 1131 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 96, "</td></tr>") | |
| 1097 | 1132 | if templ_7745c5c3_Err != nil { | |
| 1098 | 1133 | return templ_7745c5c3_Err | |
| 1099 | 1134 | } | |
| 1100 | 1135 | for _, ln := range h.Lines { | |
| 1101 | - | var templ_7745c5c3_Var59 = []any{ln.Kind} | |
| 1102 | - | templ_7745c5c3_Err = templ.RenderCSSItems(ctx, templ_7745c5c3_Buffer, templ_7745c5c3_Var59...) | |
| 1136 | + | var templ_7745c5c3_Var60 = []any{ln.Kind} | |
| 1137 | + | templ_7745c5c3_Err = templ.RenderCSSItems(ctx, templ_7745c5c3_Buffer, templ_7745c5c3_Var60...) | |
| 1103 | 1138 | if templ_7745c5c3_Err != nil { | |
| 1104 | 1139 | return templ_7745c5c3_Err | |
| 1105 | 1140 | } | |
| 1106 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 96, "<tr class=\"") | |
| 1141 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 97, "<tr class=\"") | |
| 1107 | 1142 | if templ_7745c5c3_Err != nil { | |
| 1108 | 1143 | return templ_7745c5c3_Err | |
| 1109 | 1144 | } | |
| 1110 | - | var templ_7745c5c3_Var60 string | |
| 1111 | - | templ_7745c5c3_Var60, templ_7745c5c3_Err = templ.ResolveAttributeValue(templ.CSSClasses(templ_7745c5c3_Var59).String()) | |
| 1145 | + | var templ_7745c5c3_Var61 string | |
| 1146 | + | templ_7745c5c3_Var61, templ_7745c5c3_Err = templ.ResolveAttributeValue(templ.CSSClasses(templ_7745c5c3_Var60).String()) | |
| 1112 | 1147 | if templ_7745c5c3_Err != nil { | |
| 1113 | 1148 | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 1, Col: 0} | |
| 1114 | 1149 | } | |
| 1115 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var60) | |
| 1150 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var61) | |
| 1116 | 1151 | if templ_7745c5c3_Err != nil { | |
| 1117 | 1152 | return templ_7745c5c3_Err | |
| 1118 | 1153 | } | |
| 1119 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 97, "\"><td class=\"ln\">") | |
| 1154 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 98, "\"><td class=\"ln\">") | |
| 1120 | 1155 | if templ_7745c5c3_Err != nil { | |
| 1121 | 1156 | return templ_7745c5c3_Err | |
| 1122 | 1157 | } | |
| @@ -1124,7 +1159,7 @@ func DiffFileView(f DiffFile, p DiffView) templ.Component { | |||
| 1124 | 1159 | if templ_7745c5c3_Err != nil { | |
| 1125 | 1160 | return templ_7745c5c3_Err | |
| 1126 | 1161 | } | |
| 1127 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 98, "</td><td class=\"ln\">") | |
| 1162 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 99, "</td><td class=\"ln\">") | |
| 1128 | 1163 | if templ_7745c5c3_Err != nil { | |
| 1129 | 1164 | return templ_7745c5c3_Err | |
| 1130 | 1165 | } | |
| @@ -1132,20 +1167,20 @@ func DiffFileView(f DiffFile, p DiffView) templ.Component { | |||
| 1132 | 1167 | if templ_7745c5c3_Err != nil { | |
| 1133 | 1168 | return templ_7745c5c3_Err | |
| 1134 | 1169 | } | |
| 1135 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 99, "</td><td class=\"m\">") | |
| 1170 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 100, "</td><td class=\"m\">") | |
| 1136 | 1171 | if templ_7745c5c3_Err != nil { | |
| 1137 | 1172 | return templ_7745c5c3_Err | |
| 1138 | 1173 | } | |
| 1139 | - | var templ_7745c5c3_Var61 string | |
| 1140 | - | templ_7745c5c3_Var61, templ_7745c5c3_Err = templ.JoinStringErrs(ln.Mark) | |
| 1174 | + | var templ_7745c5c3_Var62 string | |
| 1175 | + | templ_7745c5c3_Var62, templ_7745c5c3_Err = templ.JoinStringErrs(ln.Mark) | |
| 1141 | 1176 | if templ_7745c5c3_Err != nil { | |
| 1142 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 180, Col: 33} | |
| 1177 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 188, Col: 33} | |
| 1143 | 1178 | } | |
| 1144 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var61)) | |
| 1179 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var62)) | |
| 1145 | 1180 | if templ_7745c5c3_Err != nil { | |
| 1146 | 1181 | return templ_7745c5c3_Err | |
| 1147 | 1182 | } | |
| 1148 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 100, "</td><td class=\"tx\">") | |
| 1183 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 101, "</td><td class=\"tx\">") | |
| 1149 | 1184 | if templ_7745c5c3_Err != nil { | |
| 1150 | 1185 | return templ_7745c5c3_Err | |
| 1151 | 1186 | } | |
| @@ -1153,12 +1188,12 @@ func DiffFileView(f DiffFile, p DiffView) templ.Component { | |||
| 1153 | 1188 | if templ_7745c5c3_Err != nil { | |
| 1154 | 1189 | return templ_7745c5c3_Err | |
| 1155 | 1190 | } | |
| 1156 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 101, "</td></tr>") | |
| 1191 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 102, "</td></tr>") | |
| 1157 | 1192 | if templ_7745c5c3_Err != nil { | |
| 1158 | 1193 | return templ_7745c5c3_Err | |
| 1159 | 1194 | } | |
| 1160 | 1195 | if len(ln.Notes) > 0 || ln.Form != nil { | |
| 1161 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 102, "<tr class=\"fnote\"><td colspan=\"3\"></td><td>") | |
| 1196 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 103, "<tr class=\"fnote\"><td colspan=\"3\"></td><td>") | |
| 1162 | 1197 | if templ_7745c5c3_Err != nil { | |
| 1163 | 1198 | return templ_7745c5c3_Err | |
| 1164 | 1199 | } | |
| @@ -1166,60 +1201,60 @@ func DiffFileView(f DiffFile, p DiffView) templ.Component { | |||
| 1166 | 1201 | if templ_7745c5c3_Err != nil { | |
| 1167 | 1202 | return templ_7745c5c3_Err | |
| 1168 | 1203 | } | |
| 1169 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 103, "</td></tr>") | |
| 1204 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 104, "</td></tr>") | |
| 1170 | 1205 | if templ_7745c5c3_Err != nil { | |
| 1171 | 1206 | return templ_7745c5c3_Err | |
| 1172 | 1207 | } | |
| 1173 | 1208 | } | |
| 1174 | 1209 | } | |
| 1175 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 104, "</tbody>") | |
| 1210 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 105, "</tbody>") | |
| 1176 | 1211 | if templ_7745c5c3_Err != nil { | |
| 1177 | 1212 | return templ_7745c5c3_Err | |
| 1178 | 1213 | } | |
| 1179 | 1214 | } | |
| 1180 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 105, "</table>") | |
| 1215 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 106, "</table>") | |
| 1181 | 1216 | if templ_7745c5c3_Err != nil { | |
| 1182 | 1217 | return templ_7745c5c3_Err | |
| 1183 | 1218 | } | |
| 1184 | 1219 | } | |
| 1185 | 1220 | if p.ShowSplit { | |
| 1186 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 106, "<table class=\"dt spl\" aria-label=\"") | |
| 1221 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 107, "<table class=\"dt spl\" aria-label=\"") | |
| 1187 | 1222 | if templ_7745c5c3_Err != nil { | |
| 1188 | 1223 | return templ_7745c5c3_Err | |
| 1189 | 1224 | } | |
| 1190 | - | var templ_7745c5c3_Var62 string | |
| 1191 | - | templ_7745c5c3_Var62, templ_7745c5c3_Err = templ.ResolveAttributeValue(f.Path + ", split") | |
| 1225 | + | var templ_7745c5c3_Var63 string | |
| 1226 | + | templ_7745c5c3_Var63, templ_7745c5c3_Err = templ.ResolveAttributeValue(f.Path + ", split") | |
| 1192 | 1227 | if templ_7745c5c3_Err != nil { | |
| 1193 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 195, Col: 58} | |
| 1228 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 203, Col: 58} | |
| 1194 | 1229 | } | |
| 1195 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var62) | |
| 1230 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var63) | |
| 1196 | 1231 | if templ_7745c5c3_Err != nil { | |
| 1197 | 1232 | return templ_7745c5c3_Err | |
| 1198 | 1233 | } | |
| 1199 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 107, "\"><colgroup><col class=\"c-ln\"><col class=\"c-m\"><col><col class=\"c-ln\"><col class=\"c-m\"><col></colgroup> ") | |
| 1234 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 108, "\"><colgroup><col class=\"c-ln\"><col class=\"c-m\"><col><col class=\"c-ln\"><col class=\"c-m\"><col></colgroup> ") | |
| 1200 | 1235 | if templ_7745c5c3_Err != nil { | |
| 1201 | 1236 | return templ_7745c5c3_Err | |
| 1202 | 1237 | } | |
| 1203 | 1238 | for _, h := range f.Hunks { | |
| 1204 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 108, "<tbody><tr class=\"hunk\"><td colspan=\"6\">") | |
| 1239 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 109, "<tbody><tr class=\"hunk\"><td colspan=\"6\">") | |
| 1205 | 1240 | if templ_7745c5c3_Err != nil { | |
| 1206 | 1241 | return templ_7745c5c3_Err | |
| 1207 | 1242 | } | |
| 1208 | - | var templ_7745c5c3_Var63 string | |
| 1209 | - | templ_7745c5c3_Var63, templ_7745c5c3_Err = templ.JoinStringErrs(h.Header) | |
| 1243 | + | var templ_7745c5c3_Var64 string | |
| 1244 | + | templ_7745c5c3_Var64, templ_7745c5c3_Err = templ.JoinStringErrs(h.Header) | |
| 1210 | 1245 | if templ_7745c5c3_Err != nil { | |
| 1211 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 199, Col: 51} | |
| 1246 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 207, Col: 51} | |
| 1212 | 1247 | } | |
| 1213 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var63)) | |
| 1248 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var64)) | |
| 1214 | 1249 | if templ_7745c5c3_Err != nil { | |
| 1215 | 1250 | return templ_7745c5c3_Err | |
| 1216 | 1251 | } | |
| 1217 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 109, "</td></tr>") | |
| 1252 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 110, "</td></tr>") | |
| 1218 | 1253 | if templ_7745c5c3_Err != nil { | |
| 1219 | 1254 | return templ_7745c5c3_Err | |
| 1220 | 1255 | } | |
| 1221 | 1256 | for _, row := range h.Split { | |
| 1222 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 110, "<tr>") | |
| 1257 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 111, "<tr>") | |
| 1223 | 1258 | if templ_7745c5c3_Err != nil { | |
| 1224 | 1259 | return templ_7745c5c3_Err | |
| 1225 | 1260 | } | |
| @@ -1231,12 +1266,12 @@ func DiffFileView(f DiffFile, p DiffView) templ.Component { | |||
| 1231 | 1266 | if templ_7745c5c3_Err != nil { | |
| 1232 | 1267 | return templ_7745c5c3_Err | |
| 1233 | 1268 | } | |
| 1234 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 111, "</tr>") | |
| 1269 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 112, "</tr>") | |
| 1235 | 1270 | if templ_7745c5c3_Err != nil { | |
| 1236 | 1271 | return templ_7745c5c3_Err | |
| 1237 | 1272 | } | |
| 1238 | 1273 | if notes, form := row.Notes(), row.Form(); len(notes) > 0 || form != nil { | |
| 1239 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 112, "<tr class=\"fnote\"><td colspan=\"6\">") | |
| 1274 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 113, "<tr class=\"fnote\"><td colspan=\"6\">") | |
| 1240 | 1275 | if templ_7745c5c3_Err != nil { | |
| 1241 | 1276 | return templ_7745c5c3_Err | |
| 1242 | 1277 | } | |
| @@ -1244,53 +1279,53 @@ func DiffFileView(f DiffFile, p DiffView) templ.Component { | |||
| 1244 | 1279 | if templ_7745c5c3_Err != nil { | |
| 1245 | 1280 | return templ_7745c5c3_Err | |
| 1246 | 1281 | } | |
| 1247 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 113, "</td></tr>") | |
| 1282 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 114, "</td></tr>") | |
| 1248 | 1283 | if templ_7745c5c3_Err != nil { | |
| 1249 | 1284 | return templ_7745c5c3_Err | |
| 1250 | 1285 | } | |
| 1251 | 1286 | } | |
| 1252 | 1287 | } | |
| 1253 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 114, "</tbody>") | |
| 1288 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 115, "</tbody>") | |
| 1254 | 1289 | if templ_7745c5c3_Err != nil { | |
| 1255 | 1290 | return templ_7745c5c3_Err | |
| 1256 | 1291 | } | |
| 1257 | 1292 | } | |
| 1258 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 115, "</table>") | |
| 1293 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 116, "</table>") | |
| 1259 | 1294 | if templ_7745c5c3_Err != nil { | |
| 1260 | 1295 | return templ_7745c5c3_Err | |
| 1261 | 1296 | } | |
| 1262 | 1297 | } | |
| 1263 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 116, "</div>") | |
| 1298 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 117, "</div>") | |
| 1264 | 1299 | if templ_7745c5c3_Err != nil { | |
| 1265 | 1300 | return templ_7745c5c3_Err | |
| 1266 | 1301 | } | |
| 1267 | 1302 | } else { | |
| 1268 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 117, "<p class=\"note pad\">") | |
| 1303 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 118, "<p class=\"note pad\">") | |
| 1269 | 1304 | if templ_7745c5c3_Err != nil { | |
| 1270 | 1305 | return templ_7745c5c3_Err | |
| 1271 | 1306 | } | |
| 1272 | 1307 | if f.Note != "" { | |
| 1273 | - | var templ_7745c5c3_Var64 string | |
| 1274 | - | templ_7745c5c3_Var64, templ_7745c5c3_Err = templ.JoinStringErrs(f.Note) | |
| 1308 | + | var templ_7745c5c3_Var65 string | |
| 1309 | + | templ_7745c5c3_Var65, templ_7745c5c3_Err = templ.JoinStringErrs(f.Note) | |
| 1275 | 1310 | if templ_7745c5c3_Err != nil { | |
| 1276 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 219, Col: 13} | |
| 1311 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 227, Col: 13} | |
| 1277 | 1312 | } | |
| 1278 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var64)) | |
| 1313 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var65)) | |
| 1279 | 1314 | if templ_7745c5c3_Err != nil { | |
| 1280 | 1315 | return templ_7745c5c3_Err | |
| 1281 | 1316 | } | |
| 1282 | 1317 | } else { | |
| 1283 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 118, "no textual change.") | |
| 1318 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 119, "no textual change.") | |
| 1284 | 1319 | if templ_7745c5c3_Err != nil { | |
| 1285 | 1320 | return templ_7745c5c3_Err | |
| 1286 | 1321 | } | |
| 1287 | 1322 | } | |
| 1288 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 119, "</p>") | |
| 1323 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 120, "</p>") | |
| 1289 | 1324 | if templ_7745c5c3_Err != nil { | |
| 1290 | 1325 | return templ_7745c5c3_Err | |
| 1291 | 1326 | } | |
| 1292 | 1327 | } | |
| 1293 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 120, "</details>") | |
| 1328 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 121, "</details>") | |
| 1294 | 1329 | if templ_7745c5c3_Err != nil { | |
| 1295 | 1330 | return templ_7745c5c3_Err | |
| 1296 | 1331 | } | |
| @@ -1316,36 +1351,36 @@ func splitSide(ln *DiffLine, old bool) templ.Component { | |||
| 1316 | 1351 | }() | |
| 1317 | 1352 | } | |
| 1318 | 1353 | ctx = templ.InitializeContext(ctx) | |
| 1319 | - | templ_7745c5c3_Var65 := templ.GetChildren(ctx) | |
| 1320 | - | if templ_7745c5c3_Var65 == nil { | |
| 1321 | - | templ_7745c5c3_Var65 = templ.NopComponent | |
| 1354 | + | templ_7745c5c3_Var66 := templ.GetChildren(ctx) | |
| 1355 | + | if templ_7745c5c3_Var66 == nil { | |
| 1356 | + | templ_7745c5c3_Var66 = templ.NopComponent | |
| 1322 | 1357 | } | |
| 1323 | 1358 | ctx = templ.ClearChildren(ctx) | |
| 1324 | 1359 | if ln == nil { | |
| 1325 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 121, "<td class=\"ln none\"></td><td class=\"m none\"></td><td class=\"tx none\"></td>") | |
| 1360 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 122, "<td class=\"ln none\"></td><td class=\"m none\"></td><td class=\"tx none\"></td>") | |
| 1326 | 1361 | if templ_7745c5c3_Err != nil { | |
| 1327 | 1362 | return templ_7745c5c3_Err | |
| 1328 | 1363 | } | |
| 1329 | 1364 | } else { | |
| 1330 | - | var templ_7745c5c3_Var66 = []any{"ln", ln.Kind} | |
| 1331 | - | templ_7745c5c3_Err = templ.RenderCSSItems(ctx, templ_7745c5c3_Buffer, templ_7745c5c3_Var66...) | |
| 1365 | + | var templ_7745c5c3_Var67 = []any{"ln", ln.Kind} | |
| 1366 | + | templ_7745c5c3_Err = templ.RenderCSSItems(ctx, templ_7745c5c3_Buffer, templ_7745c5c3_Var67...) | |
| 1332 | 1367 | if templ_7745c5c3_Err != nil { | |
| 1333 | 1368 | return templ_7745c5c3_Err | |
| 1334 | 1369 | } | |
| 1335 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 122, "<td class=\"") | |
| 1370 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 123, "<td class=\"") | |
| 1336 | 1371 | if templ_7745c5c3_Err != nil { | |
| 1337 | 1372 | return templ_7745c5c3_Err | |
| 1338 | 1373 | } | |
| 1339 | - | var templ_7745c5c3_Var67 string | |
| 1340 | - | templ_7745c5c3_Var67, templ_7745c5c3_Err = templ.ResolveAttributeValue(templ.CSSClasses(templ_7745c5c3_Var66).String()) | |
| 1374 | + | var templ_7745c5c3_Var68 string | |
| 1375 | + | templ_7745c5c3_Var68, templ_7745c5c3_Err = templ.ResolveAttributeValue(templ.CSSClasses(templ_7745c5c3_Var67).String()) | |
| 1341 | 1376 | if templ_7745c5c3_Err != nil { | |
| 1342 | 1377 | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 1, Col: 0} | |
| 1343 | 1378 | } | |
| 1344 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var67) | |
| 1379 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var68) | |
| 1345 | 1380 | if templ_7745c5c3_Err != nil { | |
| 1346 | 1381 | return templ_7745c5c3_Err | |
| 1347 | 1382 | } | |
| 1348 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 123, "\">") | |
| 1383 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 124, "\">") | |
| 1349 | 1384 | if templ_7745c5c3_Err != nil { | |
| 1350 | 1385 | return templ_7745c5c3_Err | |
| 1351 | 1386 | } | |
| @@ -1360,64 +1395,64 @@ func splitSide(ln *DiffLine, old bool) templ.Component { | |||
| 1360 | 1395 | return templ_7745c5c3_Err | |
| 1361 | 1396 | } | |
| 1362 | 1397 | } | |
| 1363 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 124, "</td>") | |
| 1398 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 125, "</td>") | |
| 1364 | 1399 | if templ_7745c5c3_Err != nil { | |
| 1365 | 1400 | return templ_7745c5c3_Err | |
| 1366 | 1401 | } | |
| 1367 | - | var templ_7745c5c3_Var68 = []any{"m", ln.Kind} | |
| 1368 | - | templ_7745c5c3_Err = templ.RenderCSSItems(ctx, templ_7745c5c3_Buffer, templ_7745c5c3_Var68...) | |
| 1402 | + | var templ_7745c5c3_Var69 = []any{"m", ln.Kind} | |
| 1403 | + | templ_7745c5c3_Err = templ.RenderCSSItems(ctx, templ_7745c5c3_Buffer, templ_7745c5c3_Var69...) | |
| 1369 | 1404 | if templ_7745c5c3_Err != nil { | |
| 1370 | 1405 | return templ_7745c5c3_Err | |
| 1371 | 1406 | } | |
| 1372 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 125, "<td class=\"") | |
| 1407 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 126, "<td class=\"") | |
| 1373 | 1408 | if templ_7745c5c3_Err != nil { | |
| 1374 | 1409 | return templ_7745c5c3_Err | |
| 1375 | 1410 | } | |
| 1376 | - | var templ_7745c5c3_Var69 string | |
| 1377 | - | templ_7745c5c3_Var69, templ_7745c5c3_Err = templ.ResolveAttributeValue(templ.CSSClasses(templ_7745c5c3_Var68).String()) | |
| 1411 | + | var templ_7745c5c3_Var70 string | |
| 1412 | + | templ_7745c5c3_Var70, templ_7745c5c3_Err = templ.ResolveAttributeValue(templ.CSSClasses(templ_7745c5c3_Var69).String()) | |
| 1378 | 1413 | if templ_7745c5c3_Err != nil { | |
| 1379 | 1414 | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 1, Col: 0} | |
| 1380 | 1415 | } | |
| 1381 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var69) | |
| 1416 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var70) | |
| 1382 | 1417 | if templ_7745c5c3_Err != nil { | |
| 1383 | 1418 | return templ_7745c5c3_Err | |
| 1384 | 1419 | } | |
| 1385 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 126, "\">") | |
| 1420 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 127, "\">") | |
| 1386 | 1421 | if templ_7745c5c3_Err != nil { | |
| 1387 | 1422 | return templ_7745c5c3_Err | |
| 1388 | 1423 | } | |
| 1389 | - | var templ_7745c5c3_Var70 string | |
| 1390 | - | templ_7745c5c3_Var70, templ_7745c5c3_Err = templ.JoinStringErrs(ln.Mark) | |
| 1424 | + | var templ_7745c5c3_Var71 string | |
| 1425 | + | templ_7745c5c3_Var71, templ_7745c5c3_Err = templ.JoinStringErrs(ln.Mark) | |
| 1391 | 1426 | if templ_7745c5c3_Err != nil { | |
| 1392 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 243, Col: 38} | |
| 1427 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 251, Col: 38} | |
| 1393 | 1428 | } | |
| 1394 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var70)) | |
| 1429 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var71)) | |
| 1395 | 1430 | if templ_7745c5c3_Err != nil { | |
| 1396 | 1431 | return templ_7745c5c3_Err | |
| 1397 | 1432 | } | |
| 1398 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 127, "</td>") | |
| 1433 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 128, "</td>") | |
| 1399 | 1434 | if templ_7745c5c3_Err != nil { | |
| 1400 | 1435 | return templ_7745c5c3_Err | |
| 1401 | 1436 | } | |
| 1402 | - | var templ_7745c5c3_Var71 = []any{"tx", ln.Kind} | |
| 1403 | - | templ_7745c5c3_Err = templ.RenderCSSItems(ctx, templ_7745c5c3_Buffer, templ_7745c5c3_Var71...) | |
| 1437 | + | var templ_7745c5c3_Var72 = []any{"tx", ln.Kind} | |
| 1438 | + | templ_7745c5c3_Err = templ.RenderCSSItems(ctx, templ_7745c5c3_Buffer, templ_7745c5c3_Var72...) | |
| 1404 | 1439 | if templ_7745c5c3_Err != nil { | |
| 1405 | 1440 | return templ_7745c5c3_Err | |
| 1406 | 1441 | } | |
| 1407 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 128, "<td class=\"") | |
| 1442 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 129, "<td class=\"") | |
| 1408 | 1443 | if templ_7745c5c3_Err != nil { | |
| 1409 | 1444 | return templ_7745c5c3_Err | |
| 1410 | 1445 | } | |
| 1411 | - | var templ_7745c5c3_Var72 string | |
| 1412 | - | templ_7745c5c3_Var72, templ_7745c5c3_Err = templ.ResolveAttributeValue(templ.CSSClasses(templ_7745c5c3_Var71).String()) | |
| 1446 | + | var templ_7745c5c3_Var73 string | |
| 1447 | + | templ_7745c5c3_Var73, templ_7745c5c3_Err = templ.ResolveAttributeValue(templ.CSSClasses(templ_7745c5c3_Var72).String()) | |
| 1413 | 1448 | if templ_7745c5c3_Err != nil { | |
| 1414 | 1449 | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 1, Col: 0} | |
| 1415 | 1450 | } | |
| 1416 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var72) | |
| 1451 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var73) | |
| 1417 | 1452 | if templ_7745c5c3_Err != nil { | |
| 1418 | 1453 | return templ_7745c5c3_Err | |
| 1419 | 1454 | } | |
| 1420 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 129, "\">") | |
| 1455 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 130, "\">") | |
| 1421 | 1456 | if templ_7745c5c3_Err != nil { | |
| 1422 | 1457 | return templ_7745c5c3_Err | |
| 1423 | 1458 | } | |
| @@ -1425,7 +1460,7 @@ func splitSide(ln *DiffLine, old bool) templ.Component { | |||
| 1425 | 1460 | if templ_7745c5c3_Err != nil { | |
| 1426 | 1461 | return templ_7745c5c3_Err | |
| 1427 | 1462 | } | |
| 1428 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 130, "</td>") | |
| 1463 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 131, "</td>") | |
| 1429 | 1464 | if templ_7745c5c3_Err != nil { | |
| 1430 | 1465 | return templ_7745c5c3_Err | |
| 1431 | 1466 | } | |
| @@ -1452,49 +1487,49 @@ func gutter(n, href string) templ.Component { | |||
| 1452 | 1487 | }() | |
| 1453 | 1488 | } | |
| 1454 | 1489 | ctx = templ.InitializeContext(ctx) | |
| 1455 | - | templ_7745c5c3_Var73 := templ.GetChildren(ctx) | |
| 1456 | - | if templ_7745c5c3_Var73 == nil { | |
| 1457 | - | templ_7745c5c3_Var73 = templ.NopComponent | |
| 1490 | + | templ_7745c5c3_Var74 := templ.GetChildren(ctx) | |
| 1491 | + | if templ_7745c5c3_Var74 == nil { | |
| 1492 | + | templ_7745c5c3_Var74 = templ.NopComponent | |
| 1458 | 1493 | } | |
| 1459 | 1494 | ctx = templ.ClearChildren(ctx) | |
| 1460 | 1495 | if href != "" { | |
| 1461 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 131, "<a href=\"") | |
| 1496 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 132, "<a href=\"") | |
| 1462 | 1497 | if templ_7745c5c3_Err != nil { | |
| 1463 | 1498 | return templ_7745c5c3_Err | |
| 1464 | 1499 | } | |
| 1465 | - | var templ_7745c5c3_Var74 templ.SafeURL | |
| 1466 | - | templ_7745c5c3_Var74, templ_7745c5c3_Err = templ.JoinURLErrs(templ.SafeURL(href)) | |
| 1500 | + | var templ_7745c5c3_Var75 templ.SafeURL | |
| 1501 | + | templ_7745c5c3_Var75, templ_7745c5c3_Err = templ.JoinURLErrs(templ.SafeURL(href)) | |
| 1467 | 1502 | if templ_7745c5c3_Err != nil { | |
| 1468 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 252, Col: 31} | |
| 1503 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 260, Col: 31} | |
| 1469 | 1504 | } | |
| 1470 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var74)) | |
| 1505 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var75)) | |
| 1471 | 1506 | if templ_7745c5c3_Err != nil { | |
| 1472 | 1507 | return templ_7745c5c3_Err | |
| 1473 | 1508 | } | |
| 1474 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 132, "\" title=\"comment on this line\">") | |
| 1509 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 133, "\" title=\"comment on this line\">") | |
| 1475 | 1510 | if templ_7745c5c3_Err != nil { | |
| 1476 | 1511 | return templ_7745c5c3_Err | |
| 1477 | 1512 | } | |
| 1478 | - | var templ_7745c5c3_Var75 string | |
| 1479 | - | templ_7745c5c3_Var75, templ_7745c5c3_Err = templ.JoinStringErrs(n) | |
| 1513 | + | var templ_7745c5c3_Var76 string | |
| 1514 | + | templ_7745c5c3_Var76, templ_7745c5c3_Err = templ.JoinStringErrs(n) | |
| 1480 | 1515 | if templ_7745c5c3_Err != nil { | |
| 1481 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 252, Col: 66} | |
| 1516 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 260, Col: 66} | |
| 1482 | 1517 | } | |
| 1483 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var75)) | |
| 1518 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var76)) | |
| 1484 | 1519 | if templ_7745c5c3_Err != nil { | |
| 1485 | 1520 | return templ_7745c5c3_Err | |
| 1486 | 1521 | } | |
| 1487 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 133, "</a>") | |
| 1522 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 134, "</a>") | |
| 1488 | 1523 | if templ_7745c5c3_Err != nil { | |
| 1489 | 1524 | return templ_7745c5c3_Err | |
| 1490 | 1525 | } | |
| 1491 | 1526 | } else { | |
| 1492 | - | var templ_7745c5c3_Var76 string | |
| 1493 | - | templ_7745c5c3_Var76, templ_7745c5c3_Err = templ.JoinStringErrs(n) | |
| 1527 | + | var templ_7745c5c3_Var77 string | |
| 1528 | + | templ_7745c5c3_Var77, templ_7745c5c3_Err = templ.JoinStringErrs(n) | |
| 1494 | 1529 | if templ_7745c5c3_Err != nil { | |
| 1495 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 254, Col: 5} | |
| 1530 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 262, Col: 5} | |
| 1496 | 1531 | } | |
| 1497 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var76)) | |
| 1532 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var77)) | |
| 1498 | 1533 | if templ_7745c5c3_Err != nil { | |
| 1499 | 1534 | return templ_7745c5c3_Err | |
| 1500 | 1535 | } | |
| @@ -282,7 +282,11 @@ func Commit(l Layout, p CommitPage) templ.Component { | |||||
| 282 | if templ_7745c5c3_Err != nil { | 282 | if templ_7745c5c3_Err != nil { | ||
| 283 | return templ_7745c5c3_Err | 283 | return templ_7745c5c3_Err | ||
| 284 | } | 284 | } | ||
| 285 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 27, "<button type=\"button\" aria-keyshortcuts=\"x\" hx-on:click=\"document.body.dispatchEvent(new CustomEvent('k-collapse'))\" class=\"btn\">Collapse all<kbd aria-hidden=\"true\">x</kbd></button></div>") | 285 | + | templ_7745c5c3_Err = collapseButton().Render(ctx, templ_7745c5c3_Buffer) |
| 286 | + | if templ_7745c5c3_Err != nil { | |||
| 287 | + | return templ_7745c5c3_Err | |||
| 288 | + | } | |||
| 289 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 27, "</div>") | |||
| 286 | if templ_7745c5c3_Err != nil { | 290 | if templ_7745c5c3_Err != nil { | ||
| 287 | return templ_7745c5c3_Err | 291 | return templ_7745c5c3_Err | ||
| 288 | } | 292 | } | ||
| @@ -546,7 +550,9 @@ func viewLink(p DiffView, view, label, key, href string) templ.Component { | |||||
| 546 | }) | 550 | }) | ||
| 547 | } | 551 | } | ||
| 548 | 552 | ||||
| 549 | - | func personView(pr Person) templ.Component { | 553 | + | // collapseButton folds every file of the diff, or opens them all again when |
| 554 | + | // none is open; its label follows the state. | |||
| 555 | + | func collapseButton() templ.Component { | |||
| 550 | return templruntime.GeneratedTemplate(func(templ_7745c5c3_Input templruntime.GeneratedComponentInput) (templ_7745c5c3_Err error) { | 556 | return templruntime.GeneratedTemplate(func(templ_7745c5c3_Input templruntime.GeneratedComponentInput) (templ_7745c5c3_Err error) { | ||
| 551 | templ_7745c5c3_W, ctx := templ_7745c5c3_Input.Writer, templ_7745c5c3_Input.Context | 557 | templ_7745c5c3_W, ctx := templ_7745c5c3_Input.Writer, templ_7745c5c3_Input.Context | ||
| 552 | if templ_7745c5c3_CtxErr := ctx.Err(); templ_7745c5c3_CtxErr != nil { | 558 | if templ_7745c5c3_CtxErr := ctx.Err(); templ_7745c5c3_CtxErr != nil { | ||
| @@ -567,78 +573,107 @@ func personView(pr Person) templ.Component { | |||||
| 567 | templ_7745c5c3_Var25 = templ.NopComponent | 573 | templ_7745c5c3_Var25 = templ.NopComponent | ||
| 568 | } | 574 | } | ||
| 569 | ctx = templ.ClearChildren(ctx) | 575 | ctx = templ.ClearChildren(ctx) | ||
| 570 | - | var templ_7745c5c3_Var26 string | 576 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 55, "<button type=\"button\" aria-keyshortcuts=\"x\" hx-on:click=\"document.body.dispatchEvent(new CustomEvent('k-collapse'))\" class=\"btn\"><span hx-live=\"this.textContent = q('[data-file][open]').count || !q('[data-file]').count ? 'Collapse all' : 'Expand all'\">Collapse all</span><kbd aria-hidden=\"true\">x</kbd></button>") |
| 571 | - | templ_7745c5c3_Var26, templ_7745c5c3_Err = templ.JoinStringErrs(pr.Name) | 577 | + | if templ_7745c5c3_Err != nil { |
| 578 | + | return templ_7745c5c3_Err | |||
| 579 | + | } | |||
| 580 | + | return nil | |||
| 581 | + | }) | |||
| 582 | + | } | |||
| 583 | + | ||||
| 584 | + | func personView(pr Person) templ.Component { | |||
| 585 | + | return templruntime.GeneratedTemplate(func(templ_7745c5c3_Input templruntime.GeneratedComponentInput) (templ_7745c5c3_Err error) { | |||
| 586 | + | templ_7745c5c3_W, ctx := templ_7745c5c3_Input.Writer, templ_7745c5c3_Input.Context | |||
| 587 | + | if templ_7745c5c3_CtxErr := ctx.Err(); templ_7745c5c3_CtxErr != nil { | |||
| 588 | + | return templ_7745c5c3_CtxErr | |||
| 589 | + | } | |||
| 590 | + | templ_7745c5c3_Buffer, templ_7745c5c3_IsBuffer := templruntime.GetBuffer(templ_7745c5c3_W) | |||
| 591 | + | if !templ_7745c5c3_IsBuffer { | |||
| 592 | + | defer func() { | |||
| 593 | + | templ_7745c5c3_BufErr := templruntime.ReleaseBuffer(templ_7745c5c3_Buffer) | |||
| 594 | + | if templ_7745c5c3_Err == nil { | |||
| 595 | + | templ_7745c5c3_Err = templ_7745c5c3_BufErr | |||
| 596 | + | } | |||
| 597 | + | }() | |||
| 598 | + | } | |||
| 599 | + | ctx = templ.InitializeContext(ctx) | |||
| 600 | + | templ_7745c5c3_Var26 := templ.GetChildren(ctx) | |||
| 601 | + | if templ_7745c5c3_Var26 == nil { | |||
| 602 | + | templ_7745c5c3_Var26 = templ.NopComponent | |||
| 603 | + | } | |||
| 604 | + | ctx = templ.ClearChildren(ctx) | |||
| 605 | + | var templ_7745c5c3_Var27 string | |||
| 606 | + | templ_7745c5c3_Var27, templ_7745c5c3_Err = templ.JoinStringErrs(pr.Name) | |||
| 572 | if templ_7745c5c3_Err != nil { | 607 | if templ_7745c5c3_Err != nil { | ||
| 573 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 116, Col: 10} | 608 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 124, Col: 10} |
| 574 | } | 609 | } | ||
| 575 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var26)) | 610 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var27)) |
| 576 | if templ_7745c5c3_Err != nil { | 611 | if templ_7745c5c3_Err != nil { | ||
| 577 | return templ_7745c5c3_Err | 612 | return templ_7745c5c3_Err | ||
| 578 | } | 613 | } | ||
| 579 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 55, " ") | 614 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 56, " ") |
| 580 | if templ_7745c5c3_Err != nil { | 615 | if templ_7745c5c3_Err != nil { | ||
| 581 | return templ_7745c5c3_Err | 616 | return templ_7745c5c3_Err | ||
| 582 | } | 617 | } | ||
| 583 | if pr.WhenAt != "" { | 618 | if pr.WhenAt != "" { | ||
| 584 | - | var templ_7745c5c3_Var27 string | 619 | + | var templ_7745c5c3_Var28 string |
| 585 | - | templ_7745c5c3_Var27, templ_7745c5c3_Err = templ.JoinStringErrs(" · ") | 620 | + | templ_7745c5c3_Var28, templ_7745c5c3_Err = templ.JoinStringErrs(" · ") |
| 586 | if templ_7745c5c3_Err != nil { | 621 | if templ_7745c5c3_Err != nil { | ||
| 587 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 118, Col: 10} | 622 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 126, Col: 10} |
| 588 | } | 623 | } | ||
| 589 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var27)) | 624 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var28)) |
| 590 | if templ_7745c5c3_Err != nil { | 625 | if templ_7745c5c3_Err != nil { | ||
| 591 | return templ_7745c5c3_Err | 626 | return templ_7745c5c3_Err | ||
| 592 | } | 627 | } | ||
| 593 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 56, "<time datetime=\"") | 628 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 57, "<time datetime=\"") |
| 594 | if templ_7745c5c3_Err != nil { | 629 | if templ_7745c5c3_Err != nil { | ||
| 595 | return templ_7745c5c3_Err | 630 | return templ_7745c5c3_Err | ||
| 596 | } | 631 | } | ||
| 597 | - | var templ_7745c5c3_Var28 string | 632 | + | var templ_7745c5c3_Var29 string |
| 598 | - | templ_7745c5c3_Var28, templ_7745c5c3_Err = templ.ResolveAttributeValue(pr.WhenAt) | 633 | + | templ_7745c5c3_Var29, templ_7745c5c3_Err = templ.ResolveAttributeValue(pr.WhenAt) |
| 599 | if templ_7745c5c3_Err != nil { | 634 | if templ_7745c5c3_Err != nil { | ||
| 600 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 118, Col: 38} | 635 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 126, Col: 38} |
| 601 | } | 636 | } | ||
| 602 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var28) | 637 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var29) |
| 603 | if templ_7745c5c3_Err != nil { | 638 | if templ_7745c5c3_Err != nil { | ||
| 604 | return templ_7745c5c3_Err | 639 | return templ_7745c5c3_Err | ||
| 605 | } | 640 | } | ||
| 606 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 57, "\" title=\"") | 641 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 58, "\" title=\"") |
| 607 | if templ_7745c5c3_Err != nil { | 642 | if templ_7745c5c3_Err != nil { | ||
| 608 | return templ_7745c5c3_Err | 643 | return templ_7745c5c3_Err | ||
| 609 | } | 644 | } | ||
| 610 | - | var templ_7745c5c3_Var29 string | 645 | + | var templ_7745c5c3_Var30 string |
| 611 | - | templ_7745c5c3_Var29, templ_7745c5c3_Err = templ.ResolveAttributeValue(pr.Abs) | 646 | + | templ_7745c5c3_Var30, templ_7745c5c3_Err = templ.ResolveAttributeValue(pr.Abs) |
| 612 | if templ_7745c5c3_Err != nil { | 647 | if templ_7745c5c3_Err != nil { | ||
| 613 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 118, Col: 55} | 648 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 126, Col: 55} |
| 614 | } | 649 | } | ||
| 615 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var29) | 650 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var30) |
| 616 | if templ_7745c5c3_Err != nil { | 651 | if templ_7745c5c3_Err != nil { | ||
| 617 | return templ_7745c5c3_Err | 652 | return templ_7745c5c3_Err | ||
| 618 | } | 653 | } | ||
| 619 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 58, "\">") | 654 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 59, "\">") |
| 620 | if templ_7745c5c3_Err != nil { | 655 | if templ_7745c5c3_Err != nil { | ||
| 621 | return templ_7745c5c3_Err | 656 | return templ_7745c5c3_Err | ||
| 622 | } | 657 | } | ||
| 623 | - | var templ_7745c5c3_Var30 string | 658 | + | var templ_7745c5c3_Var31 string |
| 624 | - | templ_7745c5c3_Var30, templ_7745c5c3_Err = templ.JoinStringErrs(pr.When) | 659 | + | templ_7745c5c3_Var31, templ_7745c5c3_Err = templ.JoinStringErrs(pr.When) |
| 625 | if templ_7745c5c3_Err != nil { | 660 | if templ_7745c5c3_Err != nil { | ||
| 626 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 118, Col: 67} | 661 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 126, Col: 67} |
| 627 | } | 662 | } | ||
| 628 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var30)) | 663 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var31)) |
| 629 | if templ_7745c5c3_Err != nil { | 664 | if templ_7745c5c3_Err != nil { | ||
| 630 | return templ_7745c5c3_Err | 665 | return templ_7745c5c3_Err | ||
| 631 | } | 666 | } | ||
| 632 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 59, "</time>") | 667 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 60, "</time>") |
| 633 | if templ_7745c5c3_Err != nil { | 668 | if templ_7745c5c3_Err != nil { | ||
| 634 | return templ_7745c5c3_Err | 669 | return templ_7745c5c3_Err | ||
| 635 | } | 670 | } | ||
| 636 | - | var templ_7745c5c3_Var31 string | 671 | + | var templ_7745c5c3_Var32 string |
| 637 | - | templ_7745c5c3_Var31, templ_7745c5c3_Err = templ.JoinStringErrs(" · " + pr.Abs) | 672 | + | templ_7745c5c3_Var32, templ_7745c5c3_Err = templ.JoinStringErrs(" · " + pr.Abs) |
| 638 | if templ_7745c5c3_Err != nil { | 673 | if templ_7745c5c3_Err != nil { | ||
| 639 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 118, Col: 93} | 674 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 126, Col: 93} |
| 640 | } | 675 | } | ||
| 641 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var31)) | 676 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var32)) |
| 642 | if templ_7745c5c3_Err != nil { | 677 | if templ_7745c5c3_Err != nil { | ||
| 643 | return templ_7745c5c3_Err | 678 | return templ_7745c5c3_Err | ||
| 644 | } | 679 | } | ||
| @@ -663,25 +698,25 @@ func commitRail(p CommitPage) templ.Component { | |||||
| 663 | }() | 698 | }() | ||
| 664 | } | 699 | } | ||
| 665 | ctx = templ.InitializeContext(ctx) | 700 | ctx = templ.InitializeContext(ctx) | ||
| 666 | - | templ_7745c5c3_Var32 := templ.GetChildren(ctx) | 701 | + | templ_7745c5c3_Var33 := templ.GetChildren(ctx) |
| 667 | - | if templ_7745c5c3_Var32 == nil { | 702 | + | if templ_7745c5c3_Var33 == nil { |
| 668 | - | templ_7745c5c3_Var32 = templ.NopComponent | 703 | + | templ_7745c5c3_Var33 = templ.NopComponent |
| 669 | } | 704 | } | ||
| 670 | ctx = templ.ClearChildren(ctx) | 705 | ctx = templ.ClearChildren(ctx) | ||
| 671 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 60, "<section aria-labelledby=\"r-files\"><h2 id=\"r-files\">Files <span class=\"count\">") | 706 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 61, "<section aria-labelledby=\"r-files\"><h2 id=\"r-files\">Files <span class=\"count\">") |
| 672 | if templ_7745c5c3_Err != nil { | 707 | if templ_7745c5c3_Err != nil { | ||
| 673 | return templ_7745c5c3_Err | 708 | return templ_7745c5c3_Err | ||
| 674 | } | 709 | } | ||
| 675 | - | var templ_7745c5c3_Var33 string | 710 | + | var templ_7745c5c3_Var34 string |
| 676 | - | templ_7745c5c3_Var33, templ_7745c5c3_Err = templ.JoinStringErrs(itoa(len(p.Files))) | 711 | + | templ_7745c5c3_Var34, templ_7745c5c3_Err = templ.JoinStringErrs(itoa(len(p.Files))) |
| 677 | if templ_7745c5c3_Err != nil { | 712 | if templ_7745c5c3_Err != nil { | ||
| 678 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 124, Col: 65} | 713 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 132, Col: 65} |
| 679 | } | 714 | } | ||
| 680 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var33)) | 715 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var34)) |
| 681 | if templ_7745c5c3_Err != nil { | 716 | if templ_7745c5c3_Err != nil { | ||
| 682 | return templ_7745c5c3_Err | 717 | return templ_7745c5c3_Err | ||
| 683 | } | 718 | } | ||
| 684 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 61, "</span></h2>") | 719 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 62, "</span></h2>") |
| 685 | if templ_7745c5c3_Err != nil { | 720 | if templ_7745c5c3_Err != nil { | ||
| 686 | return templ_7745c5c3_Err | 721 | return templ_7745c5c3_Err | ||
| 687 | } | 722 | } | ||
| @@ -689,7 +724,7 @@ func commitRail(p CommitPage) templ.Component { | |||||
| 689 | if templ_7745c5c3_Err != nil { | 724 | if templ_7745c5c3_Err != nil { | ||
| 690 | return templ_7745c5c3_Err | 725 | return templ_7745c5c3_Err | ||
| 691 | } | 726 | } | ||
| 692 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 62, "</section>") | 727 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 63, "</section>") |
| 693 | if templ_7745c5c3_Err != nil { | 728 | if templ_7745c5c3_Err != nil { | ||
| 694 | return templ_7745c5c3_Err | 729 | return templ_7745c5c3_Err | ||
| 695 | } | 730 | } | ||
| @@ -715,165 +750,165 @@ func FileList(files []DiffFile) templ.Component { | |||||
| 715 | }() | 750 | }() | ||
| 716 | } | 751 | } | ||
| 717 | ctx = templ.InitializeContext(ctx) | 752 | ctx = templ.InitializeContext(ctx) | ||
| 718 | - | templ_7745c5c3_Var34 := templ.GetChildren(ctx) | 753 | + | templ_7745c5c3_Var35 := templ.GetChildren(ctx) |
| 719 | - | if templ_7745c5c3_Var34 == nil { | 754 | + | if templ_7745c5c3_Var35 == nil { |
| 720 | - | templ_7745c5c3_Var34 = templ.NopComponent | 755 | + | templ_7745c5c3_Var35 = templ.NopComponent |
| 721 | } | 756 | } | ||
| 722 | ctx = templ.ClearChildren(ctx) | 757 | ctx = templ.ClearChildren(ctx) | ||
| 723 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 63, "<ol class=\"files\" aria-label=\"Changed files\">") | 758 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 64, "<ol class=\"files\" aria-label=\"Changed files\">") |
| 724 | if templ_7745c5c3_Err != nil { | 759 | if templ_7745c5c3_Err != nil { | ||
| 725 | return templ_7745c5c3_Err | 760 | return templ_7745c5c3_Err | ||
| 726 | } | 761 | } | ||
| 727 | for _, f := range files { | 762 | for _, f := range files { | ||
| 728 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 64, "<li><a href=\"") | 763 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 65, "<li><a href=\"") |
| 729 | if templ_7745c5c3_Err != nil { | 764 | if templ_7745c5c3_Err != nil { | ||
| 730 | return templ_7745c5c3_Err | 765 | return templ_7745c5c3_Err | ||
| 731 | } | 766 | } | ||
| 732 | - | var templ_7745c5c3_Var35 templ.SafeURL | 767 | + | var templ_7745c5c3_Var36 templ.SafeURL |
| 733 | - | templ_7745c5c3_Var35, templ_7745c5c3_Err = templ.JoinURLErrs(templ.SafeURL("#" + f.ID)) | 768 | + | templ_7745c5c3_Var36, templ_7745c5c3_Err = templ.JoinURLErrs(templ.SafeURL("#" + f.ID)) |
| 734 | if templ_7745c5c3_Err != nil { | 769 | if templ_7745c5c3_Err != nil { | ||
| 735 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 136, Col: 37} | 770 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 144, Col: 37} |
| 736 | } | 771 | } | ||
| 737 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var35)) | 772 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var36)) |
| 738 | if templ_7745c5c3_Err != nil { | 773 | if templ_7745c5c3_Err != nil { | ||
| 739 | return templ_7745c5c3_Err | 774 | return templ_7745c5c3_Err | ||
| 740 | } | 775 | } | ||
| 741 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 65, "\" :aria-current=\"") | 776 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 66, "\" :aria-current=\"") |
| 742 | - | if templ_7745c5c3_Err != nil { | |||
| 743 | - | return templ_7745c5c3_Err | |||
| 744 | - | } | |||
| 745 | - | var templ_7745c5c3_Var36 string | |||
| 746 | - | templ_7745c5c3_Var36, templ_7745c5c3_Err = templ.ResolveAttributeValue("(() => { let all = q('.dfile').arr(); let cur = all.filter(f => f.getBoundingClientRect().top < innerHeight / 3).at(-1) || all[0]; return cur?.id === '" + f.ID + "' ? 'true' : false })()") | |||
| 747 | - | if templ_7745c5c3_Err != nil { | |||
| 748 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 137, Col: 209} | |||
| 749 | - | } | |||
| 750 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var36) | |||
| 751 | - | if templ_7745c5c3_Err != nil { | |||
| 752 | - | return templ_7745c5c3_Err | |||
| 753 | - | } | |||
| 754 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 66, "\" hx-on:click=\"document.getElementById(this.hash.slice(1)).open = true\"><span class=\"st\" title=\"") | |||
| 755 | if templ_7745c5c3_Err != nil { | 777 | if templ_7745c5c3_Err != nil { | ||
| 756 | return templ_7745c5c3_Err | 778 | return templ_7745c5c3_Err | ||
| 757 | } | 779 | } | ||
| 758 | var templ_7745c5c3_Var37 string | 780 | var templ_7745c5c3_Var37 string | ||
| 759 | - | templ_7745c5c3_Var37, templ_7745c5c3_Err = templ.ResolveAttributeValue(f.Status) | 781 | + | templ_7745c5c3_Var37, templ_7745c5c3_Err = templ.ResolveAttributeValue("(() => { let all = q('.dfile').arr(); let cur = all.filter(f => f.getBoundingClientRect().top < innerHeight / 3).at(-1) || all[0]; return cur?.id === '" + f.ID + "' ? 'true' : false })()") |
| 760 | if templ_7745c5c3_Err != nil { | 782 | if templ_7745c5c3_Err != nil { | ||
| 761 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 140, Col: 38} | 783 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 145, Col: 209} |
| 762 | } | 784 | } | ||
| 763 | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var37) | 785 | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var37) | ||
| 764 | if templ_7745c5c3_Err != nil { | 786 | if templ_7745c5c3_Err != nil { | ||
| 765 | return templ_7745c5c3_Err | 787 | return templ_7745c5c3_Err | ||
| 766 | } | 788 | } | ||
| 767 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 67, "\">") | 789 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 67, "\" hx-on:click=\"document.getElementById(this.hash.slice(1)).open = true\"><span class=\"st\" title=\"") |
| 768 | if templ_7745c5c3_Err != nil { | 790 | if templ_7745c5c3_Err != nil { | ||
| 769 | return templ_7745c5c3_Err | 791 | return templ_7745c5c3_Err | ||
| 770 | } | 792 | } | ||
| 771 | var templ_7745c5c3_Var38 string | 793 | var templ_7745c5c3_Var38 string | ||
| 772 | - | templ_7745c5c3_Var38, templ_7745c5c3_Err = templ.JoinStringErrs(f.Status) | 794 | + | templ_7745c5c3_Var38, templ_7745c5c3_Err = templ.ResolveAttributeValue(f.Status) |
| 773 | if templ_7745c5c3_Err != nil { | 795 | if templ_7745c5c3_Err != nil { | ||
| 774 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 140, Col: 51} | 796 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 148, Col: 38} |
| 775 | } | 797 | } | ||
| 776 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var38)) | 798 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var38) |
| 777 | if templ_7745c5c3_Err != nil { | 799 | if templ_7745c5c3_Err != nil { | ||
| 778 | return templ_7745c5c3_Err | 800 | return templ_7745c5c3_Err | ||
| 779 | } | 801 | } | ||
| 780 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 68, "</span> <span class=\"p\" title=\"") | 802 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 68, "\">") |
| 781 | if templ_7745c5c3_Err != nil { | 803 | if templ_7745c5c3_Err != nil { | ||
| 782 | return templ_7745c5c3_Err | 804 | return templ_7745c5c3_Err | ||
| 783 | } | 805 | } | ||
| 784 | var templ_7745c5c3_Var39 string | 806 | var templ_7745c5c3_Var39 string | ||
| 785 | - | templ_7745c5c3_Var39, templ_7745c5c3_Err = templ.ResolveAttributeValue(f.Path) | 807 | + | templ_7745c5c3_Var39, templ_7745c5c3_Err = templ.JoinStringErrs(f.Status) |
| 786 | if templ_7745c5c3_Err != nil { | 808 | if templ_7745c5c3_Err != nil { | ||
| 787 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 141, Col: 35} | 809 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 148, Col: 51} |
| 788 | } | 810 | } | ||
| 789 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var39) | 811 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var39)) |
| 790 | if templ_7745c5c3_Err != nil { | 812 | if templ_7745c5c3_Err != nil { | ||
| 791 | return templ_7745c5c3_Err | 813 | return templ_7745c5c3_Err | ||
| 792 | } | 814 | } | ||
| 793 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 69, "\">") | 815 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 69, "</span> <span class=\"p\" title=\"") |
| 794 | if templ_7745c5c3_Err != nil { | 816 | if templ_7745c5c3_Err != nil { | ||
| 795 | return templ_7745c5c3_Err | 817 | return templ_7745c5c3_Err | ||
| 796 | } | 818 | } | ||
| 797 | var templ_7745c5c3_Var40 string | 819 | var templ_7745c5c3_Var40 string | ||
| 798 | - | templ_7745c5c3_Var40, templ_7745c5c3_Err = templ.JoinStringErrs(f.Path) | 820 | + | templ_7745c5c3_Var40, templ_7745c5c3_Err = templ.ResolveAttributeValue(f.Path) |
| 799 | if templ_7745c5c3_Err != nil { | 821 | if templ_7745c5c3_Err != nil { | ||
| 800 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 141, Col: 46} | 822 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 149, Col: 35} |
| 801 | } | 823 | } | ||
| 802 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var40)) | 824 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var40) |
| 803 | if templ_7745c5c3_Err != nil { | 825 | if templ_7745c5c3_Err != nil { | ||
| 804 | return templ_7745c5c3_Err | 826 | return templ_7745c5c3_Err | ||
| 805 | } | 827 | } | ||
| 806 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 70, "</span> <span class=\"n\"><span class=\"plus\">+") | 828 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 70, "\">") |
| 807 | if templ_7745c5c3_Err != nil { | 829 | if templ_7745c5c3_Err != nil { | ||
| 808 | return templ_7745c5c3_Err | 830 | return templ_7745c5c3_Err | ||
| 809 | } | 831 | } | ||
| 810 | var templ_7745c5c3_Var41 string | 832 | var templ_7745c5c3_Var41 string | ||
| 811 | - | templ_7745c5c3_Var41, templ_7745c5c3_Err = templ.JoinStringErrs(itoa(f.Add)) | 833 | + | templ_7745c5c3_Var41, templ_7745c5c3_Err = templ.JoinStringErrs(f.Path) |
| 812 | if templ_7745c5c3_Err != nil { | 834 | if templ_7745c5c3_Err != nil { | ||
| 813 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 142, Col: 54} | 835 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 149, Col: 46} |
| 814 | } | 836 | } | ||
| 815 | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var41)) | 837 | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var41)) | ||
| 816 | if templ_7745c5c3_Err != nil { | 838 | if templ_7745c5c3_Err != nil { | ||
| 817 | return templ_7745c5c3_Err | 839 | return templ_7745c5c3_Err | ||
| 818 | } | 840 | } | ||
| 819 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 71, "</span> <span class=\"minus\">-") | 841 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 71, "</span> <span class=\"n\"><span class=\"plus\">+") |
| 820 | if templ_7745c5c3_Err != nil { | 842 | if templ_7745c5c3_Err != nil { | ||
| 821 | return templ_7745c5c3_Err | 843 | return templ_7745c5c3_Err | ||
| 822 | } | 844 | } | ||
| 823 | var templ_7745c5c3_Var42 string | 845 | var templ_7745c5c3_Var42 string | ||
| 824 | - | templ_7745c5c3_Var42, templ_7745c5c3_Err = templ.JoinStringErrs(itoa(f.Del)) | 846 | + | templ_7745c5c3_Var42, templ_7745c5c3_Err = templ.JoinStringErrs(itoa(f.Add)) |
| 825 | if templ_7745c5c3_Err != nil { | 847 | if templ_7745c5c3_Err != nil { | ||
| 826 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 142, Col: 98} | 848 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 150, Col: 54} |
| 827 | } | 849 | } | ||
| 828 | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var42)) | 850 | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var42)) | ||
| 829 | if templ_7745c5c3_Err != nil { | 851 | if templ_7745c5c3_Err != nil { | ||
| 830 | return templ_7745c5c3_Err | 852 | return templ_7745c5c3_Err | ||
| 831 | } | 853 | } | ||
| 832 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 72, "</span></span> <span class=\"b\" aria-hidden=\"true\"><span class=\"plus\">") | 854 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 72, "</span> <span class=\"minus\">-") |
| 833 | if templ_7745c5c3_Err != nil { | 855 | if templ_7745c5c3_Err != nil { | ||
| 834 | return templ_7745c5c3_Err | 856 | return templ_7745c5c3_Err | ||
| 835 | } | 857 | } | ||
| 836 | var templ_7745c5c3_Var43 string | 858 | var templ_7745c5c3_Var43 string | ||
| 837 | - | templ_7745c5c3_Var43, templ_7745c5c3_Err = templ.JoinStringErrs(f.Bar.Add) | 859 | + | templ_7745c5c3_Var43, templ_7745c5c3_Err = templ.JoinStringErrs(itoa(f.Del)) |
| 838 | if templ_7745c5c3_Err != nil { | 860 | if templ_7745c5c3_Err != nil { | ||
| 839 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 143, Col: 70} | 861 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 150, Col: 98} |
| 840 | } | 862 | } | ||
| 841 | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var43)) | 863 | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var43)) | ||
| 842 | if templ_7745c5c3_Err != nil { | 864 | if templ_7745c5c3_Err != nil { | ||
| 843 | return templ_7745c5c3_Err | 865 | return templ_7745c5c3_Err | ||
| 844 | } | 866 | } | ||
| 845 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 73, "</span><span class=\"minus\">") | 867 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 73, "</span></span> <span class=\"b\" aria-hidden=\"true\"><span class=\"plus\">") |
| 846 | if templ_7745c5c3_Err != nil { | 868 | if templ_7745c5c3_Err != nil { | ||
| 847 | return templ_7745c5c3_Err | 869 | return templ_7745c5c3_Err | ||
| 848 | } | 870 | } | ||
| 849 | var templ_7745c5c3_Var44 string | 871 | var templ_7745c5c3_Var44 string | ||
| 850 | - | templ_7745c5c3_Var44, templ_7745c5c3_Err = templ.JoinStringErrs(f.Bar.Del) | 872 | + | templ_7745c5c3_Var44, templ_7745c5c3_Err = templ.JoinStringErrs(f.Bar.Add) |
| 851 | if templ_7745c5c3_Err != nil { | 873 | if templ_7745c5c3_Err != nil { | ||
| 852 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 143, Col: 110} | 874 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 151, Col: 70} |
| 853 | } | 875 | } | ||
| 854 | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var44)) | 876 | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var44)) | ||
| 855 | if templ_7745c5c3_Err != nil { | 877 | if templ_7745c5c3_Err != nil { | ||
| 856 | return templ_7745c5c3_Err | 878 | return templ_7745c5c3_Err | ||
| 857 | } | 879 | } | ||
| 858 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 74, "</span>") | 880 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 74, "</span><span class=\"minus\">") |
| 859 | if templ_7745c5c3_Err != nil { | 881 | if templ_7745c5c3_Err != nil { | ||
| 860 | return templ_7745c5c3_Err | 882 | return templ_7745c5c3_Err | ||
| 861 | } | 883 | } | ||
| 862 | var templ_7745c5c3_Var45 string | 884 | var templ_7745c5c3_Var45 string | ||
| 863 | - | templ_7745c5c3_Var45, templ_7745c5c3_Err = templ.JoinStringErrs(f.Bar.Rest) | 885 | + | templ_7745c5c3_Var45, templ_7745c5c3_Err = templ.JoinStringErrs(f.Bar.Del) |
| 864 | if templ_7745c5c3_Err != nil { | 886 | if templ_7745c5c3_Err != nil { | ||
| 865 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 143, Col: 131} | 887 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 151, Col: 110} |
| 866 | } | 888 | } | ||
| 867 | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var45)) | 889 | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var45)) | ||
| 868 | if templ_7745c5c3_Err != nil { | 890 | if templ_7745c5c3_Err != nil { | ||
| 869 | return templ_7745c5c3_Err | 891 | return templ_7745c5c3_Err | ||
| 870 | } | 892 | } | ||
| 871 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 75, "</span></a></li>") | 893 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 75, "</span>") |
| 894 | + | if templ_7745c5c3_Err != nil { | |||
| 895 | + | return templ_7745c5c3_Err | |||
| 896 | + | } | |||
| 897 | + | var templ_7745c5c3_Var46 string | |||
| 898 | + | templ_7745c5c3_Var46, templ_7745c5c3_Err = templ.JoinStringErrs(f.Bar.Rest) | |||
| 899 | + | if templ_7745c5c3_Err != nil { | |||
| 900 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 151, Col: 131} | |||
| 901 | + | } | |||
| 902 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var46)) | |||
| 903 | + | if templ_7745c5c3_Err != nil { | |||
| 904 | + | return templ_7745c5c3_Err | |||
| 905 | + | } | |||
| 906 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 76, "</span></a></li>") | |||
| 872 | if templ_7745c5c3_Err != nil { | 907 | if templ_7745c5c3_Err != nil { | ||
| 873 | return templ_7745c5c3_Err | 908 | return templ_7745c5c3_Err | ||
| 874 | } | 909 | } | ||
| 875 | } | 910 | } | ||
| 876 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 76, "</ol>") | 911 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 77, "</ol>") |
| 877 | if templ_7745c5c3_Err != nil { | 912 | if templ_7745c5c3_Err != nil { | ||
| 878 | return templ_7745c5c3_Err | 913 | return templ_7745c5c3_Err | ||
| 879 | } | 914 | } | ||
| @@ -901,222 +936,222 @@ func DiffFileView(f DiffFile, p DiffView) templ.Component { | |||||
| 901 | }() | 936 | }() | ||
| 902 | } | 937 | } | ||
| 903 | ctx = templ.InitializeContext(ctx) | 938 | ctx = templ.InitializeContext(ctx) | ||
| 904 | - | templ_7745c5c3_Var46 := templ.GetChildren(ctx) | 939 | + | templ_7745c5c3_Var47 := templ.GetChildren(ctx) |
| 905 | - | if templ_7745c5c3_Var46 == nil { | 940 | + | if templ_7745c5c3_Var47 == nil { |
| 906 | - | templ_7745c5c3_Var46 = templ.NopComponent | 941 | + | templ_7745c5c3_Var47 = templ.NopComponent |
| 907 | } | 942 | } | ||
| 908 | ctx = templ.ClearChildren(ctx) | 943 | ctx = templ.ClearChildren(ctx) | ||
| 909 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 77, "<details class=\"dfile\" id=\"") | 944 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 78, "<details class=\"dfile\" id=\"") |
| 910 | if templ_7745c5c3_Err != nil { | 945 | if templ_7745c5c3_Err != nil { | ||
| 911 | return templ_7745c5c3_Err | 946 | return templ_7745c5c3_Err | ||
| 912 | } | 947 | } | ||
| 913 | - | var templ_7745c5c3_Var47 string | 948 | + | var templ_7745c5c3_Var48 string |
| 914 | - | templ_7745c5c3_Var47, templ_7745c5c3_Err = templ.ResolveAttributeValue(f.ID) | 949 | + | templ_7745c5c3_Var48, templ_7745c5c3_Err = templ.ResolveAttributeValue(f.ID) |
| 915 | if templ_7745c5c3_Err != nil { | 950 | if templ_7745c5c3_Err != nil { | ||
| 916 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 157, Col: 11} | 951 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 165, Col: 11} |
| 917 | } | 952 | } | ||
| 918 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var47) | 953 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var48) |
| 919 | if templ_7745c5c3_Err != nil { | 954 | if templ_7745c5c3_Err != nil { | ||
| 920 | return templ_7745c5c3_Err | 955 | return templ_7745c5c3_Err | ||
| 921 | } | 956 | } | ||
| 922 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 78, "\" data-file") | 957 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 79, "\" data-file") |
| 923 | if templ_7745c5c3_Err != nil { | 958 | if templ_7745c5c3_Err != nil { | ||
| 924 | return templ_7745c5c3_Err | 959 | return templ_7745c5c3_Err | ||
| 925 | } | 960 | } | ||
| 926 | if f.Open { | 961 | if f.Open { | ||
| 927 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 79, " open") | 962 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 80, " open") |
| 928 | if templ_7745c5c3_Err != nil { | 963 | if templ_7745c5c3_Err != nil { | ||
| 929 | return templ_7745c5c3_Err | 964 | return templ_7745c5c3_Err | ||
| 930 | } | 965 | } | ||
| 931 | } | 966 | } | ||
| 932 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 80, "><summary><span class=\"st\">") | 967 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 81, "><summary><span class=\"st\">") |
| 933 | - | if templ_7745c5c3_Err != nil { | |||
| 934 | - | return templ_7745c5c3_Err | |||
| 935 | - | } | |||
| 936 | - | var templ_7745c5c3_Var48 string | |||
| 937 | - | templ_7745c5c3_Var48, templ_7745c5c3_Err = templ.JoinStringErrs(f.Status) | |||
| 938 | - | if templ_7745c5c3_Err != nil { | |||
| 939 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 164, Col: 30} | |||
| 940 | - | } | |||
| 941 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var48)) | |||
| 942 | - | if templ_7745c5c3_Err != nil { | |||
| 943 | - | return templ_7745c5c3_Err | |||
| 944 | - | } | |||
| 945 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 81, "</span>") | |||
| 946 | if templ_7745c5c3_Err != nil { | 968 | if templ_7745c5c3_Err != nil { | ||
| 947 | return templ_7745c5c3_Err | 969 | return templ_7745c5c3_Err | ||
| 948 | } | 970 | } | ||
| 949 | var templ_7745c5c3_Var49 string | 971 | var templ_7745c5c3_Var49 string | ||
| 950 | - | templ_7745c5c3_Var49, templ_7745c5c3_Err = templ.JoinStringErrs(" ") | 972 | + | templ_7745c5c3_Var49, templ_7745c5c3_Err = templ.JoinStringErrs(f.Status) |
| 951 | if templ_7745c5c3_Err != nil { | 973 | if templ_7745c5c3_Err != nil { | ||
| 952 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 164, Col: 44} | 974 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 172, Col: 30} |
| 953 | } | 975 | } | ||
| 954 | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var49)) | 976 | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var49)) | ||
| 955 | if templ_7745c5c3_Err != nil { | 977 | if templ_7745c5c3_Err != nil { | ||
| 956 | return templ_7745c5c3_Err | 978 | return templ_7745c5c3_Err | ||
| 957 | } | 979 | } | ||
| 958 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 82, "<span class=\"p\">") | 980 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 82, "</span>") |
| 959 | if templ_7745c5c3_Err != nil { | 981 | if templ_7745c5c3_Err != nil { | ||
| 960 | return templ_7745c5c3_Err | 982 | return templ_7745c5c3_Err | ||
| 961 | } | 983 | } | ||
| 962 | var templ_7745c5c3_Var50 string | 984 | var templ_7745c5c3_Var50 string | ||
| 963 | - | templ_7745c5c3_Var50, templ_7745c5c3_Err = templ.JoinStringErrs(f.Path) | 985 | + | templ_7745c5c3_Var50, templ_7745c5c3_Err = templ.JoinStringErrs(" ") |
| 964 | if templ_7745c5c3_Err != nil { | 986 | if templ_7745c5c3_Err != nil { | ||
| 965 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 164, Col: 70} | 987 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 172, Col: 44} |
| 966 | } | 988 | } | ||
| 967 | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var50)) | 989 | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var50)) | ||
| 968 | if templ_7745c5c3_Err != nil { | 990 | if templ_7745c5c3_Err != nil { | ||
| 969 | return templ_7745c5c3_Err | 991 | return templ_7745c5c3_Err | ||
| 970 | } | 992 | } | ||
| 971 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 83, "</span>") | 993 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 83, "<span class=\"p\">") |
| 972 | if templ_7745c5c3_Err != nil { | 994 | if templ_7745c5c3_Err != nil { | ||
| 973 | return templ_7745c5c3_Err | 995 | return templ_7745c5c3_Err | ||
| 974 | } | 996 | } | ||
| 975 | var templ_7745c5c3_Var51 string | 997 | var templ_7745c5c3_Var51 string | ||
| 976 | - | templ_7745c5c3_Var51, templ_7745c5c3_Err = templ.JoinStringErrs(" ") | 998 | + | templ_7745c5c3_Var51, templ_7745c5c3_Err = templ.JoinStringErrs(f.Path) |
| 977 | if templ_7745c5c3_Err != nil { | 999 | if templ_7745c5c3_Err != nil { | ||
| 978 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 164, Col: 84} | 1000 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 172, Col: 70} |
| 979 | } | 1001 | } | ||
| 980 | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var51)) | 1002 | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var51)) | ||
| 981 | if templ_7745c5c3_Err != nil { | 1003 | if templ_7745c5c3_Err != nil { | ||
| 982 | return templ_7745c5c3_Err | 1004 | return templ_7745c5c3_Err | ||
| 983 | } | 1005 | } | ||
| 984 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 84, "<span class=\"plus\">+") | 1006 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 84, "</span>") |
| 985 | if templ_7745c5c3_Err != nil { | 1007 | if templ_7745c5c3_Err != nil { | ||
| 986 | return templ_7745c5c3_Err | 1008 | return templ_7745c5c3_Err | ||
| 987 | } | 1009 | } | ||
| 988 | var templ_7745c5c3_Var52 string | 1010 | var templ_7745c5c3_Var52 string | ||
| 989 | - | templ_7745c5c3_Var52, templ_7745c5c3_Err = templ.JoinStringErrs(itoa(f.Add)) | 1011 | + | templ_7745c5c3_Var52, templ_7745c5c3_Err = templ.JoinStringErrs(" ") |
| 990 | if templ_7745c5c3_Err != nil { | 1012 | if templ_7745c5c3_Err != nil { | ||
| 991 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 164, Col: 119} | 1013 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 172, Col: 84} |
| 992 | } | 1014 | } | ||
| 993 | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var52)) | 1015 | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var52)) | ||
| 994 | if templ_7745c5c3_Err != nil { | 1016 | if templ_7745c5c3_Err != nil { | ||
| 995 | return templ_7745c5c3_Err | 1017 | return templ_7745c5c3_Err | ||
| 996 | } | 1018 | } | ||
| 997 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 85, "</span>") | 1019 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 85, "<span class=\"plus\">+") |
| 998 | if templ_7745c5c3_Err != nil { | 1020 | if templ_7745c5c3_Err != nil { | ||
| 999 | return templ_7745c5c3_Err | 1021 | return templ_7745c5c3_Err | ||
| 1000 | } | 1022 | } | ||
| 1001 | var templ_7745c5c3_Var53 string | 1023 | var templ_7745c5c3_Var53 string | ||
| 1002 | - | templ_7745c5c3_Var53, templ_7745c5c3_Err = templ.JoinStringErrs(" ") | 1024 | + | templ_7745c5c3_Var53, templ_7745c5c3_Err = templ.JoinStringErrs(itoa(f.Add)) |
| 1003 | if templ_7745c5c3_Err != nil { | 1025 | if templ_7745c5c3_Err != nil { | ||
| 1004 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 164, Col: 133} | 1026 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 172, Col: 119} |
| 1005 | } | 1027 | } | ||
| 1006 | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var53)) | 1028 | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var53)) | ||
| 1007 | if templ_7745c5c3_Err != nil { | 1029 | if templ_7745c5c3_Err != nil { | ||
| 1008 | return templ_7745c5c3_Err | 1030 | return templ_7745c5c3_Err | ||
| 1009 | } | 1031 | } | ||
| 1010 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 86, "<span class=\"minus\">-") | 1032 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 86, "</span>") |
| 1011 | if templ_7745c5c3_Err != nil { | 1033 | if templ_7745c5c3_Err != nil { | ||
| 1012 | return templ_7745c5c3_Err | 1034 | return templ_7745c5c3_Err | ||
| 1013 | } | 1035 | } | ||
| 1014 | var templ_7745c5c3_Var54 string | 1036 | var templ_7745c5c3_Var54 string | ||
| 1015 | - | templ_7745c5c3_Var54, templ_7745c5c3_Err = templ.JoinStringErrs(itoa(f.Del)) | 1037 | + | templ_7745c5c3_Var54, templ_7745c5c3_Err = templ.JoinStringErrs(" ") |
| 1016 | if templ_7745c5c3_Err != nil { | 1038 | if templ_7745c5c3_Err != nil { | ||
| 1017 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 164, Col: 169} | 1039 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 172, Col: 133} |
| 1018 | } | 1040 | } | ||
| 1019 | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var54)) | 1041 | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var54)) | ||
| 1020 | if templ_7745c5c3_Err != nil { | 1042 | if templ_7745c5c3_Err != nil { | ||
| 1021 | return templ_7745c5c3_Err | 1043 | return templ_7745c5c3_Err | ||
| 1022 | } | 1044 | } | ||
| 1023 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 87, "</span> ") | 1045 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 87, "<span class=\"minus\">-") |
| 1046 | + | if templ_7745c5c3_Err != nil { | |||
| 1047 | + | return templ_7745c5c3_Err | |||
| 1048 | + | } | |||
| 1049 | + | var templ_7745c5c3_Var55 string | |||
| 1050 | + | templ_7745c5c3_Var55, templ_7745c5c3_Err = templ.JoinStringErrs(itoa(f.Del)) | |||
| 1051 | + | if templ_7745c5c3_Err != nil { | |||
| 1052 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 172, Col: 169} | |||
| 1053 | + | } | |||
| 1054 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var55)) | |||
| 1055 | + | if templ_7745c5c3_Err != nil { | |||
| 1056 | + | return templ_7745c5c3_Err | |||
| 1057 | + | } | |||
| 1058 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 88, "</span> ") | |||
| 1024 | if templ_7745c5c3_Err != nil { | 1059 | if templ_7745c5c3_Err != nil { | ||
| 1025 | return templ_7745c5c3_Err | 1060 | return templ_7745c5c3_Err | ||
| 1026 | } | 1061 | } | ||
| 1027 | if f.Note != "" { | 1062 | if f.Note != "" { | ||
| 1028 | - | var templ_7745c5c3_Var55 string | 1063 | + | var templ_7745c5c3_Var56 string |
| 1029 | - | templ_7745c5c3_Var55, templ_7745c5c3_Err = templ.JoinStringErrs(" ") | 1064 | + | templ_7745c5c3_Var56, templ_7745c5c3_Err = templ.JoinStringErrs(" ") |
| 1030 | if templ_7745c5c3_Err != nil { | 1065 | if templ_7745c5c3_Err != nil { | ||
| 1031 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 166, Col: 9} | 1066 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 174, Col: 9} |
| 1032 | } | 1067 | } | ||
| 1033 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var55)) | 1068 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var56)) |
| 1034 | if templ_7745c5c3_Err != nil { | 1069 | if templ_7745c5c3_Err != nil { | ||
| 1035 | return templ_7745c5c3_Err | 1070 | return templ_7745c5c3_Err | ||
| 1036 | } | 1071 | } | ||
| 1037 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 88, "<span class=\"note\">") | 1072 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 89, "<span class=\"note\">") |
| 1038 | if templ_7745c5c3_Err != nil { | 1073 | if templ_7745c5c3_Err != nil { | ||
| 1039 | return templ_7745c5c3_Err | 1074 | return templ_7745c5c3_Err | ||
| 1040 | } | 1075 | } | ||
| 1041 | - | var templ_7745c5c3_Var56 string | 1076 | + | var templ_7745c5c3_Var57 string |
| 1042 | - | templ_7745c5c3_Var56, templ_7745c5c3_Err = templ.JoinStringErrs(f.Note) | 1077 | + | templ_7745c5c3_Var57, templ_7745c5c3_Err = templ.JoinStringErrs(f.Note) |
| 1043 | if templ_7745c5c3_Err != nil { | 1078 | if templ_7745c5c3_Err != nil { | ||
| 1044 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 166, Col: 38} | 1079 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 174, Col: 38} |
| 1045 | } | 1080 | } | ||
| 1046 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var56)) | 1081 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var57)) |
| 1047 | if templ_7745c5c3_Err != nil { | 1082 | if templ_7745c5c3_Err != nil { | ||
| 1048 | return templ_7745c5c3_Err | 1083 | return templ_7745c5c3_Err | ||
| 1049 | } | 1084 | } | ||
| 1050 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 89, "</span>") | 1085 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 90, "</span>") |
| 1051 | if templ_7745c5c3_Err != nil { | 1086 | if templ_7745c5c3_Err != nil { | ||
| 1052 | return templ_7745c5c3_Err | 1087 | return templ_7745c5c3_Err | ||
| 1053 | } | 1088 | } | ||
| 1054 | } | 1089 | } | ||
| 1055 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 90, "</summary> ") | 1090 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 91, "</summary> ") |
| 1056 | if templ_7745c5c3_Err != nil { | 1091 | if templ_7745c5c3_Err != nil { | ||
| 1057 | return templ_7745c5c3_Err | 1092 | return templ_7745c5c3_Err | ||
| 1058 | } | 1093 | } | ||
| 1059 | if len(f.Hunks) > 0 { | 1094 | if len(f.Hunks) > 0 { | ||
| 1060 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 91, "<div class=\"dscroll\">") | 1095 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 92, "<div class=\"dscroll\">") |
| 1061 | if templ_7745c5c3_Err != nil { | 1096 | if templ_7745c5c3_Err != nil { | ||
| 1062 | return templ_7745c5c3_Err | 1097 | return templ_7745c5c3_Err | ||
| 1063 | } | 1098 | } | ||
| 1064 | if p.ShowUnified { | 1099 | if p.ShowUnified { | ||
| 1065 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 92, "<table class=\"dt uni\" aria-label=\"") | 1100 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 93, "<table class=\"dt uni\" aria-label=\"") |
| 1066 | if templ_7745c5c3_Err != nil { | 1101 | if templ_7745c5c3_Err != nil { | ||
| 1067 | return templ_7745c5c3_Err | 1102 | return templ_7745c5c3_Err | ||
| 1068 | } | 1103 | } | ||
| 1069 | - | var templ_7745c5c3_Var57 string | 1104 | + | var templ_7745c5c3_Var58 string |
| 1070 | - | templ_7745c5c3_Var57, templ_7745c5c3_Err = templ.ResolveAttributeValue(f.Path + ", unified") | 1105 | + | templ_7745c5c3_Var58, templ_7745c5c3_Err = templ.ResolveAttributeValue(f.Path + ", unified") |
| 1071 | if templ_7745c5c3_Err != nil { | 1106 | if templ_7745c5c3_Err != nil { | ||
| 1072 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 172, Col: 60} | 1107 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 180, Col: 60} |
| 1073 | } | 1108 | } | ||
| 1074 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var57) | 1109 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var58) |
| 1075 | if templ_7745c5c3_Err != nil { | 1110 | if templ_7745c5c3_Err != nil { | ||
| 1076 | return templ_7745c5c3_Err | 1111 | return templ_7745c5c3_Err | ||
| 1077 | } | 1112 | } | ||
| 1078 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 93, "\">") | 1113 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 94, "\">") |
| 1079 | if templ_7745c5c3_Err != nil { | 1114 | if templ_7745c5c3_Err != nil { | ||
| 1080 | return templ_7745c5c3_Err | 1115 | return templ_7745c5c3_Err | ||
| 1081 | } | 1116 | } | ||
| 1082 | for _, h := range f.Hunks { | 1117 | for _, h := range f.Hunks { | ||
| 1083 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 94, "<tbody><tr class=\"hunk\"><td colspan=\"4\">") | 1118 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 95, "<tbody><tr class=\"hunk\"><td colspan=\"4\">") |
| 1084 | if templ_7745c5c3_Err != nil { | 1119 | if templ_7745c5c3_Err != nil { | ||
| 1085 | return templ_7745c5c3_Err | 1120 | return templ_7745c5c3_Err | ||
| 1086 | } | 1121 | } | ||
| 1087 | - | var templ_7745c5c3_Var58 string | 1122 | + | var templ_7745c5c3_Var59 string |
| 1088 | - | templ_7745c5c3_Var58, templ_7745c5c3_Err = templ.JoinStringErrs(h.Header) | 1123 | + | templ_7745c5c3_Var59, templ_7745c5c3_Err = templ.JoinStringErrs(h.Header) |
| 1089 | if templ_7745c5c3_Err != nil { | 1124 | if templ_7745c5c3_Err != nil { | ||
| 1090 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 175, Col: 51} | 1125 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 183, Col: 51} |
| 1091 | } | 1126 | } | ||
| 1092 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var58)) | 1127 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var59)) |
| 1093 | if templ_7745c5c3_Err != nil { | 1128 | if templ_7745c5c3_Err != nil { | ||
| 1094 | return templ_7745c5c3_Err | 1129 | return templ_7745c5c3_Err | ||
| 1095 | } | 1130 | } | ||
| 1096 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 95, "</td></tr>") | 1131 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 96, "</td></tr>") |
| 1097 | if templ_7745c5c3_Err != nil { | 1132 | if templ_7745c5c3_Err != nil { | ||
| 1098 | return templ_7745c5c3_Err | 1133 | return templ_7745c5c3_Err | ||
| 1099 | } | 1134 | } | ||
| 1100 | for _, ln := range h.Lines { | 1135 | for _, ln := range h.Lines { | ||
| 1101 | - | var templ_7745c5c3_Var59 = []any{ln.Kind} | 1136 | + | var templ_7745c5c3_Var60 = []any{ln.Kind} |
| 1102 | - | templ_7745c5c3_Err = templ.RenderCSSItems(ctx, templ_7745c5c3_Buffer, templ_7745c5c3_Var59...) | 1137 | + | templ_7745c5c3_Err = templ.RenderCSSItems(ctx, templ_7745c5c3_Buffer, templ_7745c5c3_Var60...) |
| 1103 | if templ_7745c5c3_Err != nil { | 1138 | if templ_7745c5c3_Err != nil { | ||
| 1104 | return templ_7745c5c3_Err | 1139 | return templ_7745c5c3_Err | ||
| 1105 | } | 1140 | } | ||
| 1106 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 96, "<tr class=\"") | 1141 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 97, "<tr class=\"") |
| 1107 | if templ_7745c5c3_Err != nil { | 1142 | if templ_7745c5c3_Err != nil { | ||
| 1108 | return templ_7745c5c3_Err | 1143 | return templ_7745c5c3_Err | ||
| 1109 | } | 1144 | } | ||
| 1110 | - | var templ_7745c5c3_Var60 string | 1145 | + | var templ_7745c5c3_Var61 string |
| 1111 | - | templ_7745c5c3_Var60, templ_7745c5c3_Err = templ.ResolveAttributeValue(templ.CSSClasses(templ_7745c5c3_Var59).String()) | 1146 | + | templ_7745c5c3_Var61, templ_7745c5c3_Err = templ.ResolveAttributeValue(templ.CSSClasses(templ_7745c5c3_Var60).String()) |
| 1112 | if templ_7745c5c3_Err != nil { | 1147 | if templ_7745c5c3_Err != nil { | ||
| 1113 | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 1, Col: 0} | 1148 | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 1, Col: 0} | ||
| 1114 | } | 1149 | } | ||
| 1115 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var60) | 1150 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var61) |
| 1116 | if templ_7745c5c3_Err != nil { | 1151 | if templ_7745c5c3_Err != nil { | ||
| 1117 | return templ_7745c5c3_Err | 1152 | return templ_7745c5c3_Err | ||
| 1118 | } | 1153 | } | ||
| 1119 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 97, "\"><td class=\"ln\">") | 1154 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 98, "\"><td class=\"ln\">") |
| 1120 | if templ_7745c5c3_Err != nil { | 1155 | if templ_7745c5c3_Err != nil { | ||
| 1121 | return templ_7745c5c3_Err | 1156 | return templ_7745c5c3_Err | ||
| 1122 | } | 1157 | } | ||
| @@ -1124,7 +1159,7 @@ func DiffFileView(f DiffFile, p DiffView) templ.Component { | |||||
| 1124 | if templ_7745c5c3_Err != nil { | 1159 | if templ_7745c5c3_Err != nil { | ||
| 1125 | return templ_7745c5c3_Err | 1160 | return templ_7745c5c3_Err | ||
| 1126 | } | 1161 | } | ||
| 1127 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 98, "</td><td class=\"ln\">") | 1162 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 99, "</td><td class=\"ln\">") |
| 1128 | if templ_7745c5c3_Err != nil { | 1163 | if templ_7745c5c3_Err != nil { | ||
| 1129 | return templ_7745c5c3_Err | 1164 | return templ_7745c5c3_Err | ||
| 1130 | } | 1165 | } | ||
| @@ -1132,20 +1167,20 @@ func DiffFileView(f DiffFile, p DiffView) templ.Component { | |||||
| 1132 | if templ_7745c5c3_Err != nil { | 1167 | if templ_7745c5c3_Err != nil { | ||
| 1133 | return templ_7745c5c3_Err | 1168 | return templ_7745c5c3_Err | ||
| 1134 | } | 1169 | } | ||
| 1135 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 99, "</td><td class=\"m\">") | 1170 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 100, "</td><td class=\"m\">") |
| 1136 | if templ_7745c5c3_Err != nil { | 1171 | if templ_7745c5c3_Err != nil { | ||
| 1137 | return templ_7745c5c3_Err | 1172 | return templ_7745c5c3_Err | ||
| 1138 | } | 1173 | } | ||
| 1139 | - | var templ_7745c5c3_Var61 string | 1174 | + | var templ_7745c5c3_Var62 string |
| 1140 | - | templ_7745c5c3_Var61, templ_7745c5c3_Err = templ.JoinStringErrs(ln.Mark) | 1175 | + | templ_7745c5c3_Var62, templ_7745c5c3_Err = templ.JoinStringErrs(ln.Mark) |
| 1141 | if templ_7745c5c3_Err != nil { | 1176 | if templ_7745c5c3_Err != nil { | ||
| 1142 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 180, Col: 33} | 1177 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 188, Col: 33} |
| 1143 | } | 1178 | } | ||
| 1144 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var61)) | 1179 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var62)) |
| 1145 | if templ_7745c5c3_Err != nil { | 1180 | if templ_7745c5c3_Err != nil { | ||
| 1146 | return templ_7745c5c3_Err | 1181 | return templ_7745c5c3_Err | ||
| 1147 | } | 1182 | } | ||
| 1148 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 100, "</td><td class=\"tx\">") | 1183 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 101, "</td><td class=\"tx\">") |
| 1149 | if templ_7745c5c3_Err != nil { | 1184 | if templ_7745c5c3_Err != nil { | ||
| 1150 | return templ_7745c5c3_Err | 1185 | return templ_7745c5c3_Err | ||
| 1151 | } | 1186 | } | ||
| @@ -1153,12 +1188,12 @@ func DiffFileView(f DiffFile, p DiffView) templ.Component { | |||||
| 1153 | if templ_7745c5c3_Err != nil { | 1188 | if templ_7745c5c3_Err != nil { | ||
| 1154 | return templ_7745c5c3_Err | 1189 | return templ_7745c5c3_Err | ||
| 1155 | } | 1190 | } | ||
| 1156 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 101, "</td></tr>") | 1191 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 102, "</td></tr>") |
| 1157 | if templ_7745c5c3_Err != nil { | 1192 | if templ_7745c5c3_Err != nil { | ||
| 1158 | return templ_7745c5c3_Err | 1193 | return templ_7745c5c3_Err | ||
| 1159 | } | 1194 | } | ||
| 1160 | if len(ln.Notes) > 0 || ln.Form != nil { | 1195 | if len(ln.Notes) > 0 || ln.Form != nil { | ||
| 1161 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 102, "<tr class=\"fnote\"><td colspan=\"3\"></td><td>") | 1196 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 103, "<tr class=\"fnote\"><td colspan=\"3\"></td><td>") |
| 1162 | if templ_7745c5c3_Err != nil { | 1197 | if templ_7745c5c3_Err != nil { | ||
| 1163 | return templ_7745c5c3_Err | 1198 | return templ_7745c5c3_Err | ||
| 1164 | } | 1199 | } | ||
| @@ -1166,60 +1201,60 @@ func DiffFileView(f DiffFile, p DiffView) templ.Component { | |||||
| 1166 | if templ_7745c5c3_Err != nil { | 1201 | if templ_7745c5c3_Err != nil { | ||
| 1167 | return templ_7745c5c3_Err | 1202 | return templ_7745c5c3_Err | ||
| 1168 | } | 1203 | } | ||
| 1169 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 103, "</td></tr>") | 1204 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 104, "</td></tr>") |
| 1170 | if templ_7745c5c3_Err != nil { | 1205 | if templ_7745c5c3_Err != nil { | ||
| 1171 | return templ_7745c5c3_Err | 1206 | return templ_7745c5c3_Err | ||
| 1172 | } | 1207 | } | ||
| 1173 | } | 1208 | } | ||
| 1174 | } | 1209 | } | ||
| 1175 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 104, "</tbody>") | 1210 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 105, "</tbody>") |
| 1176 | if templ_7745c5c3_Err != nil { | 1211 | if templ_7745c5c3_Err != nil { | ||
| 1177 | return templ_7745c5c3_Err | 1212 | return templ_7745c5c3_Err | ||
| 1178 | } | 1213 | } | ||
| 1179 | } | 1214 | } | ||
| 1180 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 105, "</table>") | 1215 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 106, "</table>") |
| 1181 | if templ_7745c5c3_Err != nil { | 1216 | if templ_7745c5c3_Err != nil { | ||
| 1182 | return templ_7745c5c3_Err | 1217 | return templ_7745c5c3_Err | ||
| 1183 | } | 1218 | } | ||
| 1184 | } | 1219 | } | ||
| 1185 | if p.ShowSplit { | 1220 | if p.ShowSplit { | ||
| 1186 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 106, "<table class=\"dt spl\" aria-label=\"") | 1221 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 107, "<table class=\"dt spl\" aria-label=\"") |
| 1187 | if templ_7745c5c3_Err != nil { | 1222 | if templ_7745c5c3_Err != nil { | ||
| 1188 | return templ_7745c5c3_Err | 1223 | return templ_7745c5c3_Err | ||
| 1189 | } | 1224 | } | ||
| 1190 | - | var templ_7745c5c3_Var62 string | 1225 | + | var templ_7745c5c3_Var63 string |
| 1191 | - | templ_7745c5c3_Var62, templ_7745c5c3_Err = templ.ResolveAttributeValue(f.Path + ", split") | 1226 | + | templ_7745c5c3_Var63, templ_7745c5c3_Err = templ.ResolveAttributeValue(f.Path + ", split") |
| 1192 | if templ_7745c5c3_Err != nil { | 1227 | if templ_7745c5c3_Err != nil { | ||
| 1193 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 195, Col: 58} | 1228 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 203, Col: 58} |
| 1194 | } | 1229 | } | ||
| 1195 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var62) | 1230 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var63) |
| 1196 | if templ_7745c5c3_Err != nil { | 1231 | if templ_7745c5c3_Err != nil { | ||
| 1197 | return templ_7745c5c3_Err | 1232 | return templ_7745c5c3_Err | ||
| 1198 | } | 1233 | } | ||
| 1199 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 107, "\"><colgroup><col class=\"c-ln\"><col class=\"c-m\"><col><col class=\"c-ln\"><col class=\"c-m\"><col></colgroup> ") | 1234 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 108, "\"><colgroup><col class=\"c-ln\"><col class=\"c-m\"><col><col class=\"c-ln\"><col class=\"c-m\"><col></colgroup> ") |
| 1200 | if templ_7745c5c3_Err != nil { | 1235 | if templ_7745c5c3_Err != nil { | ||
| 1201 | return templ_7745c5c3_Err | 1236 | return templ_7745c5c3_Err | ||
| 1202 | } | 1237 | } | ||
| 1203 | for _, h := range f.Hunks { | 1238 | for _, h := range f.Hunks { | ||
| 1204 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 108, "<tbody><tr class=\"hunk\"><td colspan=\"6\">") | 1239 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 109, "<tbody><tr class=\"hunk\"><td colspan=\"6\">") |
| 1205 | if templ_7745c5c3_Err != nil { | 1240 | if templ_7745c5c3_Err != nil { | ||
| 1206 | return templ_7745c5c3_Err | 1241 | return templ_7745c5c3_Err | ||
| 1207 | } | 1242 | } | ||
| 1208 | - | var templ_7745c5c3_Var63 string | 1243 | + | var templ_7745c5c3_Var64 string |
| 1209 | - | templ_7745c5c3_Var63, templ_7745c5c3_Err = templ.JoinStringErrs(h.Header) | 1244 | + | templ_7745c5c3_Var64, templ_7745c5c3_Err = templ.JoinStringErrs(h.Header) |
| 1210 | if templ_7745c5c3_Err != nil { | 1245 | if templ_7745c5c3_Err != nil { | ||
| 1211 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 199, Col: 51} | 1246 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 207, Col: 51} |
| 1212 | } | 1247 | } | ||
| 1213 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var63)) | 1248 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var64)) |
| 1214 | if templ_7745c5c3_Err != nil { | 1249 | if templ_7745c5c3_Err != nil { | ||
| 1215 | return templ_7745c5c3_Err | 1250 | return templ_7745c5c3_Err | ||
| 1216 | } | 1251 | } | ||
| 1217 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 109, "</td></tr>") | 1252 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 110, "</td></tr>") |
| 1218 | if templ_7745c5c3_Err != nil { | 1253 | if templ_7745c5c3_Err != nil { | ||
| 1219 | return templ_7745c5c3_Err | 1254 | return templ_7745c5c3_Err | ||
| 1220 | } | 1255 | } | ||
| 1221 | for _, row := range h.Split { | 1256 | for _, row := range h.Split { | ||
| 1222 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 110, "<tr>") | 1257 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 111, "<tr>") |
| 1223 | if templ_7745c5c3_Err != nil { | 1258 | if templ_7745c5c3_Err != nil { | ||
| 1224 | return templ_7745c5c3_Err | 1259 | return templ_7745c5c3_Err | ||
| 1225 | } | 1260 | } | ||
| @@ -1231,12 +1266,12 @@ func DiffFileView(f DiffFile, p DiffView) templ.Component { | |||||
| 1231 | if templ_7745c5c3_Err != nil { | 1266 | if templ_7745c5c3_Err != nil { | ||
| 1232 | return templ_7745c5c3_Err | 1267 | return templ_7745c5c3_Err | ||
| 1233 | } | 1268 | } | ||
| 1234 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 111, "</tr>") | 1269 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 112, "</tr>") |
| 1235 | if templ_7745c5c3_Err != nil { | 1270 | if templ_7745c5c3_Err != nil { | ||
| 1236 | return templ_7745c5c3_Err | 1271 | return templ_7745c5c3_Err | ||
| 1237 | } | 1272 | } | ||
| 1238 | if notes, form := row.Notes(), row.Form(); len(notes) > 0 || form != nil { | 1273 | if notes, form := row.Notes(), row.Form(); len(notes) > 0 || form != nil { | ||
| 1239 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 112, "<tr class=\"fnote\"><td colspan=\"6\">") | 1274 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 113, "<tr class=\"fnote\"><td colspan=\"6\">") |
| 1240 | if templ_7745c5c3_Err != nil { | 1275 | if templ_7745c5c3_Err != nil { | ||
| 1241 | return templ_7745c5c3_Err | 1276 | return templ_7745c5c3_Err | ||
| 1242 | } | 1277 | } | ||
| @@ -1244,53 +1279,53 @@ func DiffFileView(f DiffFile, p DiffView) templ.Component { | |||||
| 1244 | if templ_7745c5c3_Err != nil { | 1279 | if templ_7745c5c3_Err != nil { | ||
| 1245 | return templ_7745c5c3_Err | 1280 | return templ_7745c5c3_Err | ||
| 1246 | } | 1281 | } | ||
| 1247 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 113, "</td></tr>") | 1282 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 114, "</td></tr>") |
| 1248 | if templ_7745c5c3_Err != nil { | 1283 | if templ_7745c5c3_Err != nil { | ||
| 1249 | return templ_7745c5c3_Err | 1284 | return templ_7745c5c3_Err | ||
| 1250 | } | 1285 | } | ||
| 1251 | } | 1286 | } | ||
| 1252 | } | 1287 | } | ||
| 1253 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 114, "</tbody>") | 1288 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 115, "</tbody>") |
| 1254 | if templ_7745c5c3_Err != nil { | 1289 | if templ_7745c5c3_Err != nil { | ||
| 1255 | return templ_7745c5c3_Err | 1290 | return templ_7745c5c3_Err | ||
| 1256 | } | 1291 | } | ||
| 1257 | } | 1292 | } | ||
| 1258 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 115, "</table>") | 1293 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 116, "</table>") |
| 1259 | if templ_7745c5c3_Err != nil { | 1294 | if templ_7745c5c3_Err != nil { | ||
| 1260 | return templ_7745c5c3_Err | 1295 | return templ_7745c5c3_Err | ||
| 1261 | } | 1296 | } | ||
| 1262 | } | 1297 | } | ||
| 1263 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 116, "</div>") | 1298 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 117, "</div>") |
| 1264 | if templ_7745c5c3_Err != nil { | 1299 | if templ_7745c5c3_Err != nil { | ||
| 1265 | return templ_7745c5c3_Err | 1300 | return templ_7745c5c3_Err | ||
| 1266 | } | 1301 | } | ||
| 1267 | } else { | 1302 | } else { | ||
| 1268 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 117, "<p class=\"note pad\">") | 1303 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 118, "<p class=\"note pad\">") |
| 1269 | if templ_7745c5c3_Err != nil { | 1304 | if templ_7745c5c3_Err != nil { | ||
| 1270 | return templ_7745c5c3_Err | 1305 | return templ_7745c5c3_Err | ||
| 1271 | } | 1306 | } | ||
| 1272 | if f.Note != "" { | 1307 | if f.Note != "" { | ||
| 1273 | - | var templ_7745c5c3_Var64 string | 1308 | + | var templ_7745c5c3_Var65 string |
| 1274 | - | templ_7745c5c3_Var64, templ_7745c5c3_Err = templ.JoinStringErrs(f.Note) | 1309 | + | templ_7745c5c3_Var65, templ_7745c5c3_Err = templ.JoinStringErrs(f.Note) |
| 1275 | if templ_7745c5c3_Err != nil { | 1310 | if templ_7745c5c3_Err != nil { | ||
| 1276 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 219, Col: 13} | 1311 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 227, Col: 13} |
| 1277 | } | 1312 | } | ||
| 1278 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var64)) | 1313 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var65)) |
| 1279 | if templ_7745c5c3_Err != nil { | 1314 | if templ_7745c5c3_Err != nil { | ||
| 1280 | return templ_7745c5c3_Err | 1315 | return templ_7745c5c3_Err | ||
| 1281 | } | 1316 | } | ||
| 1282 | } else { | 1317 | } else { | ||
| 1283 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 118, "no textual change.") | 1318 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 119, "no textual change.") |
| 1284 | if templ_7745c5c3_Err != nil { | 1319 | if templ_7745c5c3_Err != nil { | ||
| 1285 | return templ_7745c5c3_Err | 1320 | return templ_7745c5c3_Err | ||
| 1286 | } | 1321 | } | ||
| 1287 | } | 1322 | } | ||
| 1288 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 119, "</p>") | 1323 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 120, "</p>") |
| 1289 | if templ_7745c5c3_Err != nil { | 1324 | if templ_7745c5c3_Err != nil { | ||
| 1290 | return templ_7745c5c3_Err | 1325 | return templ_7745c5c3_Err | ||
| 1291 | } | 1326 | } | ||
| 1292 | } | 1327 | } | ||
| 1293 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 120, "</details>") | 1328 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 121, "</details>") |
| 1294 | if templ_7745c5c3_Err != nil { | 1329 | if templ_7745c5c3_Err != nil { | ||
| 1295 | return templ_7745c5c3_Err | 1330 | return templ_7745c5c3_Err | ||
| 1296 | } | 1331 | } | ||
| @@ -1316,36 +1351,36 @@ func splitSide(ln *DiffLine, old bool) templ.Component { | |||||
| 1316 | }() | 1351 | }() | ||
| 1317 | } | 1352 | } | ||
| 1318 | ctx = templ.InitializeContext(ctx) | 1353 | ctx = templ.InitializeContext(ctx) | ||
| 1319 | - | templ_7745c5c3_Var65 := templ.GetChildren(ctx) | 1354 | + | templ_7745c5c3_Var66 := templ.GetChildren(ctx) |
| 1320 | - | if templ_7745c5c3_Var65 == nil { | 1355 | + | if templ_7745c5c3_Var66 == nil { |
| 1321 | - | templ_7745c5c3_Var65 = templ.NopComponent | 1356 | + | templ_7745c5c3_Var66 = templ.NopComponent |
| 1322 | } | 1357 | } | ||
| 1323 | ctx = templ.ClearChildren(ctx) | 1358 | ctx = templ.ClearChildren(ctx) | ||
| 1324 | if ln == nil { | 1359 | if ln == nil { | ||
| 1325 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 121, "<td class=\"ln none\"></td><td class=\"m none\"></td><td class=\"tx none\"></td>") | 1360 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 122, "<td class=\"ln none\"></td><td class=\"m none\"></td><td class=\"tx none\"></td>") |
| 1326 | if templ_7745c5c3_Err != nil { | 1361 | if templ_7745c5c3_Err != nil { | ||
| 1327 | return templ_7745c5c3_Err | 1362 | return templ_7745c5c3_Err | ||
| 1328 | } | 1363 | } | ||
| 1329 | } else { | 1364 | } else { | ||
| 1330 | - | var templ_7745c5c3_Var66 = []any{"ln", ln.Kind} | 1365 | + | var templ_7745c5c3_Var67 = []any{"ln", ln.Kind} |
| 1331 | - | templ_7745c5c3_Err = templ.RenderCSSItems(ctx, templ_7745c5c3_Buffer, templ_7745c5c3_Var66...) | 1366 | + | templ_7745c5c3_Err = templ.RenderCSSItems(ctx, templ_7745c5c3_Buffer, templ_7745c5c3_Var67...) |
| 1332 | if templ_7745c5c3_Err != nil { | 1367 | if templ_7745c5c3_Err != nil { | ||
| 1333 | return templ_7745c5c3_Err | 1368 | return templ_7745c5c3_Err | ||
| 1334 | } | 1369 | } | ||
| 1335 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 122, "<td class=\"") | 1370 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 123, "<td class=\"") |
| 1336 | if templ_7745c5c3_Err != nil { | 1371 | if templ_7745c5c3_Err != nil { | ||
| 1337 | return templ_7745c5c3_Err | 1372 | return templ_7745c5c3_Err | ||
| 1338 | } | 1373 | } | ||
| 1339 | - | var templ_7745c5c3_Var67 string | 1374 | + | var templ_7745c5c3_Var68 string |
| 1340 | - | templ_7745c5c3_Var67, templ_7745c5c3_Err = templ.ResolveAttributeValue(templ.CSSClasses(templ_7745c5c3_Var66).String()) | 1375 | + | templ_7745c5c3_Var68, templ_7745c5c3_Err = templ.ResolveAttributeValue(templ.CSSClasses(templ_7745c5c3_Var67).String()) |
| 1341 | if templ_7745c5c3_Err != nil { | 1376 | if templ_7745c5c3_Err != nil { | ||
| 1342 | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 1, Col: 0} | 1377 | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 1, Col: 0} | ||
| 1343 | } | 1378 | } | ||
| 1344 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var67) | 1379 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var68) |
| 1345 | if templ_7745c5c3_Err != nil { | 1380 | if templ_7745c5c3_Err != nil { | ||
| 1346 | return templ_7745c5c3_Err | 1381 | return templ_7745c5c3_Err | ||
| 1347 | } | 1382 | } | ||
| 1348 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 123, "\">") | 1383 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 124, "\">") |
| 1349 | if templ_7745c5c3_Err != nil { | 1384 | if templ_7745c5c3_Err != nil { | ||
| 1350 | return templ_7745c5c3_Err | 1385 | return templ_7745c5c3_Err | ||
| 1351 | } | 1386 | } | ||
| @@ -1360,64 +1395,64 @@ func splitSide(ln *DiffLine, old bool) templ.Component { | |||||
| 1360 | return templ_7745c5c3_Err | 1395 | return templ_7745c5c3_Err | ||
| 1361 | } | 1396 | } | ||
| 1362 | } | 1397 | } | ||
| 1363 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 124, "</td>") | 1398 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 125, "</td>") |
| 1364 | if templ_7745c5c3_Err != nil { | 1399 | if templ_7745c5c3_Err != nil { | ||
| 1365 | return templ_7745c5c3_Err | 1400 | return templ_7745c5c3_Err | ||
| 1366 | } | 1401 | } | ||
| 1367 | - | var templ_7745c5c3_Var68 = []any{"m", ln.Kind} | 1402 | + | var templ_7745c5c3_Var69 = []any{"m", ln.Kind} |
| 1368 | - | templ_7745c5c3_Err = templ.RenderCSSItems(ctx, templ_7745c5c3_Buffer, templ_7745c5c3_Var68...) | 1403 | + | templ_7745c5c3_Err = templ.RenderCSSItems(ctx, templ_7745c5c3_Buffer, templ_7745c5c3_Var69...) |
| 1369 | if templ_7745c5c3_Err != nil { | 1404 | if templ_7745c5c3_Err != nil { | ||
| 1370 | return templ_7745c5c3_Err | 1405 | return templ_7745c5c3_Err | ||
| 1371 | } | 1406 | } | ||
| 1372 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 125, "<td class=\"") | 1407 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 126, "<td class=\"") |
| 1373 | if templ_7745c5c3_Err != nil { | 1408 | if templ_7745c5c3_Err != nil { | ||
| 1374 | return templ_7745c5c3_Err | 1409 | return templ_7745c5c3_Err | ||
| 1375 | } | 1410 | } | ||
| 1376 | - | var templ_7745c5c3_Var69 string | 1411 | + | var templ_7745c5c3_Var70 string |
| 1377 | - | templ_7745c5c3_Var69, templ_7745c5c3_Err = templ.ResolveAttributeValue(templ.CSSClasses(templ_7745c5c3_Var68).String()) | 1412 | + | templ_7745c5c3_Var70, templ_7745c5c3_Err = templ.ResolveAttributeValue(templ.CSSClasses(templ_7745c5c3_Var69).String()) |
| 1378 | if templ_7745c5c3_Err != nil { | 1413 | if templ_7745c5c3_Err != nil { | ||
| 1379 | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 1, Col: 0} | 1414 | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 1, Col: 0} | ||
| 1380 | } | 1415 | } | ||
| 1381 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var69) | 1416 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var70) |
| 1382 | if templ_7745c5c3_Err != nil { | 1417 | if templ_7745c5c3_Err != nil { | ||
| 1383 | return templ_7745c5c3_Err | 1418 | return templ_7745c5c3_Err | ||
| 1384 | } | 1419 | } | ||
| 1385 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 126, "\">") | 1420 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 127, "\">") |
| 1386 | if templ_7745c5c3_Err != nil { | 1421 | if templ_7745c5c3_Err != nil { | ||
| 1387 | return templ_7745c5c3_Err | 1422 | return templ_7745c5c3_Err | ||
| 1388 | } | 1423 | } | ||
| 1389 | - | var templ_7745c5c3_Var70 string | 1424 | + | var templ_7745c5c3_Var71 string |
| 1390 | - | templ_7745c5c3_Var70, templ_7745c5c3_Err = templ.JoinStringErrs(ln.Mark) | 1425 | + | templ_7745c5c3_Var71, templ_7745c5c3_Err = templ.JoinStringErrs(ln.Mark) |
| 1391 | if templ_7745c5c3_Err != nil { | 1426 | if templ_7745c5c3_Err != nil { | ||
| 1392 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 243, Col: 38} | 1427 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 251, Col: 38} |
| 1393 | } | 1428 | } | ||
| 1394 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var70)) | 1429 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var71)) |
| 1395 | if templ_7745c5c3_Err != nil { | 1430 | if templ_7745c5c3_Err != nil { | ||
| 1396 | return templ_7745c5c3_Err | 1431 | return templ_7745c5c3_Err | ||
| 1397 | } | 1432 | } | ||
| 1398 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 127, "</td>") | 1433 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 128, "</td>") |
| 1399 | if templ_7745c5c3_Err != nil { | 1434 | if templ_7745c5c3_Err != nil { | ||
| 1400 | return templ_7745c5c3_Err | 1435 | return templ_7745c5c3_Err | ||
| 1401 | } | 1436 | } | ||
| 1402 | - | var templ_7745c5c3_Var71 = []any{"tx", ln.Kind} | 1437 | + | var templ_7745c5c3_Var72 = []any{"tx", ln.Kind} |
| 1403 | - | templ_7745c5c3_Err = templ.RenderCSSItems(ctx, templ_7745c5c3_Buffer, templ_7745c5c3_Var71...) | 1438 | + | templ_7745c5c3_Err = templ.RenderCSSItems(ctx, templ_7745c5c3_Buffer, templ_7745c5c3_Var72...) |
| 1404 | if templ_7745c5c3_Err != nil { | 1439 | if templ_7745c5c3_Err != nil { | ||
| 1405 | return templ_7745c5c3_Err | 1440 | return templ_7745c5c3_Err | ||
| 1406 | } | 1441 | } | ||
| 1407 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 128, "<td class=\"") | 1442 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 129, "<td class=\"") |
| 1408 | if templ_7745c5c3_Err != nil { | 1443 | if templ_7745c5c3_Err != nil { | ||
| 1409 | return templ_7745c5c3_Err | 1444 | return templ_7745c5c3_Err | ||
| 1410 | } | 1445 | } | ||
| 1411 | - | var templ_7745c5c3_Var72 string | 1446 | + | var templ_7745c5c3_Var73 string |
| 1412 | - | templ_7745c5c3_Var72, templ_7745c5c3_Err = templ.ResolveAttributeValue(templ.CSSClasses(templ_7745c5c3_Var71).String()) | 1447 | + | templ_7745c5c3_Var73, templ_7745c5c3_Err = templ.ResolveAttributeValue(templ.CSSClasses(templ_7745c5c3_Var72).String()) |
| 1413 | if templ_7745c5c3_Err != nil { | 1448 | if templ_7745c5c3_Err != nil { | ||
| 1414 | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 1, Col: 0} | 1449 | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 1, Col: 0} | ||
| 1415 | } | 1450 | } | ||
| 1416 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var72) | 1451 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var73) |
| 1417 | if templ_7745c5c3_Err != nil { | 1452 | if templ_7745c5c3_Err != nil { | ||
| 1418 | return templ_7745c5c3_Err | 1453 | return templ_7745c5c3_Err | ||
| 1419 | } | 1454 | } | ||
| 1420 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 129, "\">") | 1455 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 130, "\">") |
| 1421 | if templ_7745c5c3_Err != nil { | 1456 | if templ_7745c5c3_Err != nil { | ||
| 1422 | return templ_7745c5c3_Err | 1457 | return templ_7745c5c3_Err | ||
| 1423 | } | 1458 | } | ||
| @@ -1425,7 +1460,7 @@ func splitSide(ln *DiffLine, old bool) templ.Component { | |||||
| 1425 | if templ_7745c5c3_Err != nil { | 1460 | if templ_7745c5c3_Err != nil { | ||
| 1426 | return templ_7745c5c3_Err | 1461 | return templ_7745c5c3_Err | ||
| 1427 | } | 1462 | } | ||
| 1428 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 130, "</td>") | 1463 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 131, "</td>") |
| 1429 | if templ_7745c5c3_Err != nil { | 1464 | if templ_7745c5c3_Err != nil { | ||
| 1430 | return templ_7745c5c3_Err | 1465 | return templ_7745c5c3_Err | ||
| 1431 | } | 1466 | } | ||
| @@ -1452,49 +1487,49 @@ func gutter(n, href string) templ.Component { | |||||
| 1452 | }() | 1487 | }() | ||
| 1453 | } | 1488 | } | ||
| 1454 | ctx = templ.InitializeContext(ctx) | 1489 | ctx = templ.InitializeContext(ctx) | ||
| 1455 | - | templ_7745c5c3_Var73 := templ.GetChildren(ctx) | 1490 | + | templ_7745c5c3_Var74 := templ.GetChildren(ctx) |
| 1456 | - | if templ_7745c5c3_Var73 == nil { | 1491 | + | if templ_7745c5c3_Var74 == nil { |
| 1457 | - | templ_7745c5c3_Var73 = templ.NopComponent | 1492 | + | templ_7745c5c3_Var74 = templ.NopComponent |
| 1458 | } | 1493 | } | ||
| 1459 | ctx = templ.ClearChildren(ctx) | 1494 | ctx = templ.ClearChildren(ctx) | ||
| 1460 | if href != "" { | 1495 | if href != "" { | ||
| 1461 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 131, "<a href=\"") | 1496 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 132, "<a href=\"") |
| 1462 | if templ_7745c5c3_Err != nil { | 1497 | if templ_7745c5c3_Err != nil { | ||
| 1463 | return templ_7745c5c3_Err | 1498 | return templ_7745c5c3_Err | ||
| 1464 | } | 1499 | } | ||
| 1465 | - | var templ_7745c5c3_Var74 templ.SafeURL | 1500 | + | var templ_7745c5c3_Var75 templ.SafeURL |
| 1466 | - | templ_7745c5c3_Var74, templ_7745c5c3_Err = templ.JoinURLErrs(templ.SafeURL(href)) | 1501 | + | templ_7745c5c3_Var75, templ_7745c5c3_Err = templ.JoinURLErrs(templ.SafeURL(href)) |
| 1467 | if templ_7745c5c3_Err != nil { | 1502 | if templ_7745c5c3_Err != nil { | ||
| 1468 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 252, Col: 31} | 1503 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 260, Col: 31} |
| 1469 | } | 1504 | } | ||
| 1470 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var74)) | 1505 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var75)) |
| 1471 | if templ_7745c5c3_Err != nil { | 1506 | if templ_7745c5c3_Err != nil { | ||
| 1472 | return templ_7745c5c3_Err | 1507 | return templ_7745c5c3_Err | ||
| 1473 | } | 1508 | } | ||
| 1474 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 132, "\" title=\"comment on this line\">") | 1509 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 133, "\" title=\"comment on this line\">") |
| 1475 | if templ_7745c5c3_Err != nil { | 1510 | if templ_7745c5c3_Err != nil { | ||
| 1476 | return templ_7745c5c3_Err | 1511 | return templ_7745c5c3_Err | ||
| 1477 | } | 1512 | } | ||
| 1478 | - | var templ_7745c5c3_Var75 string | 1513 | + | var templ_7745c5c3_Var76 string |
| 1479 | - | templ_7745c5c3_Var75, templ_7745c5c3_Err = templ.JoinStringErrs(n) | 1514 | + | templ_7745c5c3_Var76, templ_7745c5c3_Err = templ.JoinStringErrs(n) |
| 1480 | if templ_7745c5c3_Err != nil { | 1515 | if templ_7745c5c3_Err != nil { | ||
| 1481 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 252, Col: 66} | 1516 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 260, Col: 66} |
| 1482 | } | 1517 | } | ||
| 1483 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var75)) | 1518 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var76)) |
| 1484 | if templ_7745c5c3_Err != nil { | 1519 | if templ_7745c5c3_Err != nil { | ||
| 1485 | return templ_7745c5c3_Err | 1520 | return templ_7745c5c3_Err | ||
| 1486 | } | 1521 | } | ||
| 1487 | - | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 133, "</a>") | 1522 | + | templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 134, "</a>") |
| 1488 | if templ_7745c5c3_Err != nil { | 1523 | if templ_7745c5c3_Err != nil { | ||
| 1489 | return templ_7745c5c3_Err | 1524 | return templ_7745c5c3_Err | ||
| 1490 | } | 1525 | } | ||
| 1491 | } else { | 1526 | } else { | ||
| 1492 | - | var templ_7745c5c3_Var76 string | 1527 | + | var templ_7745c5c3_Var77 string |
| 1493 | - | templ_7745c5c3_Var76, templ_7745c5c3_Err = templ.JoinStringErrs(n) | 1528 | + | templ_7745c5c3_Var77, templ_7745c5c3_Err = templ.JoinStringErrs(n) |
| 1494 | if templ_7745c5c3_Err != nil { | 1529 | if templ_7745c5c3_Err != nil { | ||
| 1495 | - | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 254, Col: 5} | 1530 | + | return templ.Error{Err: templ_7745c5c3_Err, FileName: `internal/adapters/web/diff.templ`, Line: 262, Col: 5} |
| 1496 | } | 1531 | } | ||
| 1497 | - | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var76)) | 1532 | + | _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var77)) |
| 1498 | if templ_7745c5c3_Err != nil { | 1533 | if templ_7745c5c3_Err != nil { | ||
| 1499 | return templ_7745c5c3_Err | 1534 | return templ_7745c5c3_Err | ||
| 1500 | } | 1535 | } | ||
M internal/adapters/web/keys.templ +3 -3
| @@ -52,9 +52,9 @@ templ Keys() { | |||
| 52 | 52 | let i = ns.findIndex(n => n.getBoundingClientRect().top > innerHeight / 3); | |
| 53 | 53 | let n = ns[i < 0 ? 0 : i]; n.closest('details') && (n.closest('details').open = true); n.scrollIntoView({ block: 'center' }) | |
| 54 | 54 | }; | |
| 55 | - | k-split from:body -> q('[data-diff]').attr['data-diff'] = 'split'; sessionStorage.setItem('diff', 'split'); | |
| 56 | - | k-unified from:body -> q('[data-diff]').attr['data-diff'] = 'unified'; sessionStorage.setItem('diff', 'unified'); | |
| 57 | - | k-collapse from:body -> q('[data-file]').arr().forEach(d => d.open = false); | |
| 55 | + | k-split from:body -> q('[data-diff]').attr['data-diff'] = 'split'; sessionStorage.setItem('diff', 'split'); q('[data-file]').arr().forEach(d => d.open = true); | |
| 56 | + | k-unified from:body -> q('[data-diff]').attr['data-diff'] = 'unified'; sessionStorage.setItem('diff', 'unified'); q('[data-file]').arr().forEach(d => d.open = true); | |
| 57 | + | k-collapse from:body -> { let fs = q('[data-file]').arr(), open = !fs.some(d => d.open); fs.forEach(d => d.open = open) }; | |
| 58 | 58 | k-permalink from:body -> { | |
| 59 | 59 | let b = document.body.dataset; | |
| 60 | 60 | if (!b.sha) { b.flash = 'no ref to pin on this page'; await timeout('2s'); b.flash = ''; return } | |
| @@ -52,9 +52,9 @@ templ Keys() { | |||||
| 52 | let i = ns.findIndex(n => n.getBoundingClientRect().top > innerHeight / 3); | 52 | let i = ns.findIndex(n => n.getBoundingClientRect().top > innerHeight / 3); | ||
| 53 | let n = ns[i < 0 ? 0 : i]; n.closest('details') && (n.closest('details').open = true); n.scrollIntoView({ block: 'center' }) | 53 | let n = ns[i < 0 ? 0 : i]; n.closest('details') && (n.closest('details').open = true); n.scrollIntoView({ block: 'center' }) | ||
| 54 | }; | 54 | }; | ||
| 55 | - | k-split from:body -> q('[data-diff]').attr['data-diff'] = 'split'; sessionStorage.setItem('diff', 'split'); | 55 | + | k-split from:body -> q('[data-diff]').attr['data-diff'] = 'split'; sessionStorage.setItem('diff', 'split'); q('[data-file]').arr().forEach(d => d.open = true); |
| 56 | - | k-unified from:body -> q('[data-diff]').attr['data-diff'] = 'unified'; sessionStorage.setItem('diff', 'unified'); | 56 | + | k-unified from:body -> q('[data-diff]').attr['data-diff'] = 'unified'; sessionStorage.setItem('diff', 'unified'); q('[data-file]').arr().forEach(d => d.open = true); |
| 57 | - | k-collapse from:body -> q('[data-file]').arr().forEach(d => d.open = false); | 57 | + | k-collapse from:body -> { let fs = q('[data-file]').arr(), open = !fs.some(d => d.open); fs.forEach(d => d.open = open) }; |
| 58 | k-permalink from:body -> { | 58 | k-permalink from:body -> { | ||
| 59 | let b = document.body.dataset; | 59 | let b = document.body.dataset; | ||
| 60 | if (!b.sha) { b.flash = 'no ref to pin on this page'; await timeout('2s'); b.flash = ''; return } | 60 | if (!b.sha) { b.flash = 'no ref to pin on this page'; await timeout('2s'); b.flash = ''; return } | ||
M internal/adapters/web/keys_templ.go +1 -1 generated file: collapsed
M internal/adapters/web/mr.templ +2 -2
| @@ -168,7 +168,7 @@ templ MergeRequest(l Layout, p MRPage) { | |||
| 168 | 168 | <span class="grow"></span> | |
| 169 | 169 | @viewLink(p.DiffView, "unified", "Unified", "u", p.UnifiedHref) | |
| 170 | 170 | @viewLink(p.DiffView, "split", "Split", "d", p.SplitHref) | |
| 171 | - | <button type="button" aria-keyshortcuts="x" hx-on:click="document.body.dispatchEvent(new CustomEvent('k-collapse'))" class="btn">Collapse all<kbd aria-hidden="true">x</kbd></button> | |
| 171 | + | @collapseButton() | |
| 172 | 172 | </div> | |
| 173 | 173 | if p.Invisible { | |
| 174 | 174 | <p class="notice"> | |
| @@ -448,7 +448,7 @@ templ Compare(l Layout, p ComparePage) { | |||
| 448 | 448 | <span class="grow"></span> | |
| 449 | 449 | @viewLink(p.DiffView, "unified", "Unified", "u", p.UnifiedHref) | |
| 450 | 450 | @viewLink(p.DiffView, "split", "Split", "d", p.SplitHref) | |
| 451 | - | <button type="button" aria-keyshortcuts="x" hx-on:click="document.body.dispatchEvent(new CustomEvent('k-collapse'))" class="btn">Collapse all<kbd aria-hidden="true">x</kbd></button> | |
| 451 | + | @collapseButton() | |
| 452 | 452 | </div> | |
| 453 | 453 | if p.Invisible { | |
| 454 | 454 | <p class="notice"> | |
| @@ -168,7 +168,7 @@ templ MergeRequest(l Layout, p MRPage) { | |||||
| 168 | <span class="grow"></span> | 168 | <span class="grow"></span> | ||
| 169 | @viewLink(p.DiffView, "unified", "Unified", "u", p.UnifiedHref) | 169 | @viewLink(p.DiffView, "unified", "Unified", "u", p.UnifiedHref) | ||
| 170 | @viewLink(p.DiffView, "split", "Split", "d", p.SplitHref) | 170 | @viewLink(p.DiffView, "split", "Split", "d", p.SplitHref) | ||
| 171 | - | <button type="button" aria-keyshortcuts="x" hx-on:click="document.body.dispatchEvent(new CustomEvent('k-collapse'))" class="btn">Collapse all<kbd aria-hidden="true">x</kbd></button> | 171 | + | @collapseButton() |
| 172 | </div> | 172 | </div> | ||
| 173 | if p.Invisible { | 173 | if p.Invisible { | ||
| 174 | <p class="notice"> | 174 | <p class="notice"> | ||
| @@ -448,7 +448,7 @@ templ Compare(l Layout, p ComparePage) { | |||||
| 448 | <span class="grow"></span> | 448 | <span class="grow"></span> | ||
| 449 | @viewLink(p.DiffView, "unified", "Unified", "u", p.UnifiedHref) | 449 | @viewLink(p.DiffView, "unified", "Unified", "u", p.UnifiedHref) | ||
| 450 | @viewLink(p.DiffView, "split", "Split", "d", p.SplitHref) | 450 | @viewLink(p.DiffView, "split", "Split", "d", p.SplitHref) | ||
| 451 | - | <button type="button" aria-keyshortcuts="x" hx-on:click="document.body.dispatchEvent(new CustomEvent('k-collapse'))" class="btn">Collapse all<kbd aria-hidden="true">x</kbd></button> | 451 | + | @collapseButton() |
| 452 | </div> | 452 | </div> | ||
| 453 | if p.Invisible { | 453 | if p.Invisible { | ||
| 454 | <p class="notice"> | 454 | <p class="notice"> | ||
M internal/adapters/web/mr_templ.go +10 -2 generated file: collapsed
M internal/adapters/web/overlays.templ +1 -1
| @@ -19,7 +19,7 @@ templ OverlayHelp() { | |||
| 19 | 19 | <div><dt><kbd>s</kbd> <kbd>t</kbd> <kbd>c</kbd> <kbd>r</kbd> <kbd>m</kbd></dt><dd>tabs: summary, files, commits, branches & tags, merge requests</dd></div> | |
| 20 | 20 | <div><dt><kbd>g h</kbd></dt><dd>home</dd></div> | |
| 21 | 21 | <div><dt><kbd>y</kbd></dt><dd>copy a permalink pinned to the commit</dd></div> | |
| 22 | - | <div><dt><kbd>d</kbd> <kbd>u</kbd> <kbd>x</kbd></dt><dd>diff: split / unified / collapse all</dd></div> | |
| 22 | + | <div><dt><kbd>d</kbd> <kbd>u</kbd> <kbd>x</kbd></dt><dd>diff: split / unified / collapse or expand all</dd></div> | |
| 23 | 23 | <div><dt><kbd>n</kbd></dt><dd>merge request: next note in the diff</dd></div> | |
| 24 | 24 | <div><dt><kbd>esc</kbd></dt><dd>close a dialog, leave a field</dd></div> | |
| 25 | 25 | </dl> | |
| @@ -19,7 +19,7 @@ templ OverlayHelp() { | |||||
| 19 | <div><dt><kbd>s</kbd> <kbd>t</kbd> <kbd>c</kbd> <kbd>r</kbd> <kbd>m</kbd></dt><dd>tabs: summary, files, commits, branches & tags, merge requests</dd></div> | 19 | <div><dt><kbd>s</kbd> <kbd>t</kbd> <kbd>c</kbd> <kbd>r</kbd> <kbd>m</kbd></dt><dd>tabs: summary, files, commits, branches & tags, merge requests</dd></div> | ||
| 20 | <div><dt><kbd>g h</kbd></dt><dd>home</dd></div> | 20 | <div><dt><kbd>g h</kbd></dt><dd>home</dd></div> | ||
| 21 | <div><dt><kbd>y</kbd></dt><dd>copy a permalink pinned to the commit</dd></div> | 21 | <div><dt><kbd>y</kbd></dt><dd>copy a permalink pinned to the commit</dd></div> | ||
| 22 | - | <div><dt><kbd>d</kbd> <kbd>u</kbd> <kbd>x</kbd></dt><dd>diff: split / unified / collapse all</dd></div> | 22 | + | <div><dt><kbd>d</kbd> <kbd>u</kbd> <kbd>x</kbd></dt><dd>diff: split / unified / collapse or expand all</dd></div> |
| 23 | <div><dt><kbd>n</kbd></dt><dd>merge request: next note in the diff</dd></div> | 23 | <div><dt><kbd>n</kbd></dt><dd>merge request: next note in the diff</dd></div> | ||
| 24 | <div><dt><kbd>esc</kbd></dt><dd>close a dialog, leave a field</dd></div> | 24 | <div><dt><kbd>esc</kbd></dt><dd>close a dialog, leave a field</dd></div> | ||
| 25 | </dl> | 25 | </dl> | ||