on main help sign in
chore(diffview): add missing doc comments
commitf047b18eb19f507ab1e9d68ab30571be565fffa7 authorAndrey Nering <andreynering@users.noreply.github.com> dateTue 10 Jun 2025, 17:46 (1 year ago) parent94fbd9c
1 file changed+6
internal/exp/diffview/style.go+6
internal/exp/diffview/style.go+6
@@ -5,12 +5,16 @@ import (
55 "github.com/charmbracelet/x/exp/charmtone"
66)
77
8+// LineStyle defines the styles for a given line type in the diff view.
89type LineStyle struct {
910 LineNumber lipgloss.Style
1011 Symbol lipgloss.Style
1112 Code lipgloss.Style
1213}
1314
15+// Style defines the overall style for the diff view, including styles for
16+// different line types such as divider, missing, equal, insert, and delete
17+// lines.
1418type Style struct {
1519 DividerLine LineStyle
1620 MissingLine LineStyle
@@ -19,6 +23,7 @@ type Style struct {
1923 DeleteLine LineStyle
2024}
2125
26+// DefaultLightStyle provides a default light theme style for the diff view.
2227var DefaultLightStyle = Style{
2328 DividerLine: LineStyle{
2429 LineNumber: lipgloss.NewStyle().
@@ -66,6 +71,7 @@ var DefaultLightStyle = Style{
6671 },
6772}
6873
74+// DefaultDarkStyle provides a default dark theme style for the diff view.
6975var DefaultDarkStyle = Style{
7076 DividerLine: LineStyle{
7177 LineNumber: lipgloss.NewStyle().