Skip to content

Commit 15fe388

Browse files
authored
fix(backend): default theme + README (add supported default themes) (#30)
1 parent fd9a68f commit 15fe388

5 files changed

Lines changed: 11 additions & 12 deletions

File tree

README.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ See: [lazy.nvim](https://github.com/folke/lazy.nvim)
5555
```lua
5656
{
5757
'mistweaverco/snap.nvim',
58-
version = 'v1.2.1',
58+
version = 'v1.2.2',
5959
---@type SnapUserConfig
6060
opts = {}
6161
},
@@ -71,7 +71,7 @@ See: [packer.nvim](https://github.com/wbthomason/packer.nvim)
7171
```lua
7272
use {
7373
'mistweaverco/snap.nvim',
74-
tag = 'v1.2.1',
74+
tag = 'v1.2.2',
7575
config = function()
7676

7777
---@type SnapUserConfig
@@ -90,7 +90,7 @@ use {
9090
```lua
9191
vim.pack.add({
9292
src = 'https://github.com/mistweaverco/snap.nvim.git',
93-
version = 'v1.2.1',
93+
version = 'v1.2.2',
9494
})
9595
---@type SnapUserConfig
9696
local cfg = {}
@@ -109,7 +109,7 @@ Optional. Defaults to `nil`.
109109

110110
Absolute path to a custom handlebars template file.
111111

112-
See the [default template](./templates/default.hbs) for reference.
112+
See the [builtin templates](./templates/) for reference.
113113

114114
### Configure `additional_template_data`
115115

@@ -222,7 +222,7 @@ This would then translate to the following `font_settings`:
222222
```lua
223223
return {
224224
"mistweaverco/snap.nvim",
225-
version = "v1.2.1",
225+
version = "v1.2.2",
226226
---@type SnapUserConfig
227227
opts = {
228228
template = "linux",
@@ -333,10 +333,10 @@ by running `bun install` in the plugin directory.
333333
```lua
334334
{
335335
'mistweaverco/snap.nvim',
336-
version = 'v1.2.1',
336+
version = 'v1.2.2',
337337
opts = {
338338
timeout = 5000, -- Timeout for screenshot command in milliseconds
339-
template = "default", -- Template to use for rendering screenshots (currently only "default" is supported)
339+
template = "default", -- Template to use for rendering screenshots ("default", "macos", "linux")
340340
template_filepath = nil, -- Absolute path to a custom handlebars template file (optional), overrides 'template' option
341341
-- Additional data to pass to the your custom handlebars template (optional)
342342
additional_template_data = {
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
return "1.2.1"
1+
return "1.2.2"
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
return "1.2.1"
1+
return "1.2.2"

lua/snap/highlights/utils.lua

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,6 @@ function M.get_default_bg()
2020
local hl = vim.api.nvim_get_hl(0, { name = "Normal", link = false })
2121
if hl.bg then
2222
DEFAULT_BG = M.convert_color_to_hex(hl.bg)
23-
print("Default BG:", DEFAULT_BG)
2423
end
2524
return DEFAULT_BG
2625
end

templates/default.hbs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,8 @@
1818
pre#snap {
1919
margin: 0;
2020
background-color: {{theme.bgColor}};
21-
border-bottom-left-radius: 10px;
22-
border-bottom-right-radius: 10px;
21+
border-radius: 10px;
22+
border-radius: 10px;
2323
color: {{theme.fgColor}};
2424
display: block;
2525
font-family: '{{fontSettings.fonts.default.name}}', monospace;

0 commit comments

Comments
 (0)