UI / Theme improvements

This commit is contained in:
Nate Butler
2022-07-16 11:52:30 -04:00
parent 145d59d47a
commit ef2b42c3fb
5 changed files with 28 additions and 21 deletions
+1 -1
View File
@@ -17,7 +17,7 @@ import tooltip from "./tooltip";
import terminal from "./terminal"; import terminal from "./terminal";
export const panel = { export const panel = {
padding: { top: 12, bottom: 12 }, padding: { top: 12, bottom: 12 }
}; };
export default function app(theme: Theme): Object { export default function app(theme: Theme): Object {
+5 -5
View File
@@ -35,7 +35,7 @@ export default function statusBar(theme: Theme) {
iconColor: iconColor(theme, "muted"), iconColor: iconColor(theme, "muted"),
hover: { hover: {
message: text(theme, "sans", "primary"), message: text(theme, "sans", "primary"),
iconColor: iconColor(theme, "primary"), iconColor: iconColor(theme, "active"),
background: backgroundColor(theme, 300, "hovered"), background: backgroundColor(theme, 300, "hovered"),
} }
}, },
@@ -49,7 +49,7 @@ export default function statusBar(theme: Theme) {
}, },
diagnosticSummary: { diagnosticSummary: {
height: 16, height: 16,
iconWidth: 14, iconWidth: 16,
iconSpacing: 2, iconSpacing: 2,
summarySpacing: 6, summarySpacing: 6,
text: text(theme, "sans", "primary", { size: "sm" }), text: text(theme, "sans", "primary", { size: "sm" }),
@@ -71,7 +71,7 @@ export default function statusBar(theme: Theme) {
border: border(theme, "error"), border: border(theme, "error"),
}, },
hover: { hover: {
iconColorOk: iconColor(theme, "primary"), iconColorOk: iconColor(theme, "active"),
containerOk: { containerOk: {
cornerRadius: 6, cornerRadius: 6,
padding: { top: 3, bottom: 3, left: 7, right: 7 }, padding: { top: 3, bottom: 3, left: 7, right: 7 },
@@ -94,10 +94,10 @@ export default function statusBar(theme: Theme) {
groupRight: {}, groupRight: {},
item: { item: {
...statusContainer, ...statusContainer,
iconSize: 14, iconSize: 16,
iconColor: iconColor(theme, "secondary"), iconColor: iconColor(theme, "secondary"),
hover: { hover: {
iconColor: iconColor(theme, "primary"), iconColor: iconColor(theme, "active"),
background: backgroundColor(theme, 300, "hovered"), background: backgroundColor(theme, 300, "hovered"),
}, },
active: { active: {
+1 -1
View File
@@ -14,7 +14,7 @@ export default function tooltip(theme: Theme) {
background: backgroundColor(theme, "on500"), background: backgroundColor(theme, "on500"),
cornerRadius: 4, cornerRadius: 4,
margin: { left: 6 }, margin: { left: 6 },
padding: { left: 3, right: 3 }, padding: { left: 4, right: 4 },
...text(theme, "mono", "muted", { size: "xs", weight: "bold" }) ...text(theme, "mono", "muted", { size: "xs", weight: "bold" })
}, },
maxTextWidth: 200, maxTextWidth: 200,
+17 -10
View File
@@ -60,7 +60,7 @@ export default function workspace(theme: Theme) {
border: { border: {
...tab.border ...tab.border
}, },
iconWidth: 14, iconWidth: 12,
buttonWidth: tab.height, buttonWidth: tab.height,
hover: { hover: {
color: iconColor(theme, "active"), color: iconColor(theme, "active"),
@@ -110,17 +110,24 @@ export default function workspace(theme: Theme) {
}, },
border: border(theme, "primary", { bottom: true, overlay: true }), border: border(theme, "primary", { bottom: true, overlay: true }),
signInPrompt: { signInPrompt: {
border: border(theme, "primary"), background: backgroundColor(theme, 100),
border: border(theme, "secondary"),
cornerRadius: 6, cornerRadius: 6,
margin: { margin: {
top: 1, top: 1,
}, },
padding: { padding: {
left: 6, top: 1,
right: 6, bottom: 1,
left: 7,
right: 7,
}, },
...text(theme, "sans", "secondary", { size: "xs" }), ...text(theme, "sans", "secondary", { size: "xs" }),
hover: text(theme, "sans", "active", { size: "xs" }), hover: {
...text(theme, "sans", "active", { size: "xs" }),
background: backgroundColor(theme, "on300", "hovered"),
border: border(theme, "primary"),
}
}, },
offlineIcon: { offlineIcon: {
color: iconColor(theme, "secondary"), color: iconColor(theme, "secondary"),
@@ -152,9 +159,9 @@ export default function workspace(theme: Theme) {
border: border(theme, "secondary", { bottom: true }), border: border(theme, "secondary", { bottom: true }),
itemSpacing: 8, itemSpacing: 8,
navButton: { navButton: {
color: iconColor(theme, "secondary"), color: iconColor(theme, "primary"),
iconWidth: 8, iconWidth: 12,
buttonWidth: 18, buttonWidth: 24,
cornerRadius: 6, cornerRadius: 6,
hover: { hover: {
color: iconColor(theme, "active"), color: iconColor(theme, "active"),
@@ -164,7 +171,7 @@ export default function workspace(theme: Theme) {
color: withOpacity(iconColor(theme, "muted"), 0.6), color: withOpacity(iconColor(theme, "muted"), 0.6),
}, },
}, },
padding: { left: 16, right: 8, top: 4, bottom: 4 }, padding: { left: 8, right: 8, top: 4, bottom: 4 },
}, },
breadcrumbs: { breadcrumbs: {
...text(theme, "mono", "secondary"), ...text(theme, "mono", "secondary"),
@@ -183,7 +190,7 @@ export default function workspace(theme: Theme) {
shadow: modalShadow(theme), shadow: modalShadow(theme),
}, },
notifications: { notifications: {
width: 380, width: 400,
margin: { right: 10, bottom: 10 }, margin: { right: 10, bottom: 10 },
} }
}; };
+4 -4
View File
@@ -62,13 +62,13 @@ export function createTheme(
}, },
on300: { on300: {
base: sample(ramps.neutral, 0), base: sample(ramps.neutral, 0),
hovered: sample(ramps.neutral, 0.25), hovered: sample(ramps.neutral, 0.5),
active: sample(ramps.neutral, 0.5), active: sample(ramps.neutral, 1),
}, },
on500: { on500: {
base: sample(ramps.neutral, 1.25), base: sample(ramps.neutral, 1),
hovered: sample(ramps.neutral, 1.5), hovered: sample(ramps.neutral, 1.5),
active: sample(ramps.neutral, 1.75), active: sample(ramps.neutral, 2),
}, },
ok: { ok: {
base: withOpacity(sample(ramps.green, 0.5), 0.15), base: withOpacity(sample(ramps.green, 0.5), 0.15),