feat(workspace): show git status on editor tabs

This commit is contained in:
Alex Viscreanu
2023-07-17 20:53:42 +02:00
parent 10a1df3faa
commit 6793d4b6b8
6 changed files with 74 additions and 7 deletions
+14
View File
@@ -6,6 +6,8 @@ import { useTheme } from "../common"
export default function tab_bar(): any {
const theme = useTheme()
const { is_light } = theme
const height = 32
const active_layer = theme.highest
@@ -38,6 +40,18 @@ export default function tab_bar(): any {
icon_conflict: foreground(layer, "warning"),
icon_dirty: foreground(layer, "accent"),
git: {
modified: is_light
? theme.ramps.yellow(0.6).hex()
: theme.ramps.yellow(0.5).hex(),
inserted: is_light
? theme.ramps.green(0.45).hex()
: theme.ramps.green(0.5).hex(),
conflict: is_light
? theme.ramps.red(0.6).hex()
: theme.ramps.red(0.5).hex(),
},
// When two tabs of the same name are open, a label appears next to them
description: {
margin: { left: 8 },