darrenburns / posting

The modern API client that lives in your terminal.
Apache License 2.0
4.92k stars 73 forks source link

Some colors don't change when using a custom theme #62

Closed diegoulloao closed 2 months ago

diegoulloao commented 3 months ago

Hey, I've tried my own custom theme, I can see some colors are breaking the palette, probably they aren't linked to the custom theme colors provided by the file.

../themes/custom-theme.yml

name: neofusion
primary: "#fd5e3a"
secondary: "#35b5ff"
accent: "#66def9"
background: "#06101e"
surface: "#052839"
error: "#fd5e3a"
success: "#35b5ff"
warning: "#e8e5b5"

Screenshot:

Screenshot 4
darrenburns commented 3 months ago

Good spot - I've still to update those to pull from the theme - they require a little bit extra work. Even the builtin themes don't modify those colors at the moment.

darrenburns commented 3 months ago

The response status code now pulls the $success, $warning and $error colours from the theme.

diegoulloao commented 3 months ago

The response status code now pulls the $success, $warning and $error colours from the theme.

Screenshot 4

The green one? Not seeing the colors reflected yet.

darrenburns commented 3 months ago

That's because I forgot to actually publish the release to PyPI 😂

It's in 1.9.3, I've just published it and it should become downloadable in < 15mins.

diegoulloao commented 3 months ago

Working!! Thank you

diegoulloao commented 3 months ago

What about the endpoint widget? Will it remain as it is?

darrenburns commented 3 months ago

For that I need to decide how to style it. For example if we choose the primary and accent, then we must ensure that they're readable against the background colour. I may need to specify in the docs that primary and accent must be readable against a background colour or something.

Or, I could add some extra variables to the theme, but that kind of goes against how the themes are currently expressed.

darrenburns commented 2 months ago

This is resolved in 1.10. The URL bar, variable highlighting, and JSON syntax highlighting will sample from the theme, and you can customise them using the theme file.

darrenburns commented 2 months ago

Without manually tweaking the highlighting, here's neofusion:

image
diegoulloao commented 2 months ago

Looking really good! 🔥 Screenshot is updated in the theme repository 👌🏻

darrenburns commented 2 months ago

Oh nice one :)

Out of curiosity, what do you use to capture terminal screenshots? They always look great!

diegoulloao commented 2 months ago

Oh nice one :)

Out of curiosity, what do you use to capture terminal screenshots? They always look great!

Native macOS screenshot app 😂

diegoulloao commented 2 months ago

iTerm2 for screenshots only. Kitty for personal use :)