full functionality restored (omg)

This commit is contained in:
2026-05-13 19:49:14 +01:00
parent f678372ee4
commit 0909e98a03
8 changed files with 210 additions and 237 deletions

View File

@@ -1 +1,77 @@
local beziers = {
-- Overshoot
{ name = "heavyOvershoot", points = { 0.53, 0.51, 0.4, 1.22 } },
{ name = "lightOvershoot", points = { 0.33, 0.61, 0.63, 1.19 } },
-- Linear
{ name = "smoothSnap", points = { 0.32, 0.51, 0.44, 1 } },
{ name = "smoothIn", points = { 0.25, 1, 0.5, 1 } },
{ name = "smoothOutOvershoot", points = { 0.46, -0.25, 0.81, 0.51 } },
-- Springs
{ name = "hardSpring", kind = "spring" },
{ name = "mediumSpring", kind = "spring", stiffness = 50, dampening = 10 },
{ name = "looseSpring", kind = "spring", dampening = 5, stiffness = 50 },
}
-- For every curve in the table (ik it says bezier stfu)
for _, bezier in ipairs(beziers) do
-- If there are points then its not a spring
if bezier.points then
hl.curve(bezier.name, {
type = "bezier",
points = { { bezier.points[1], bezier.points[2] }, { bezier.points[3], bezier.points[4] } },
})
-- If its a spring
elseif bezier.kind == "spring" then
hl.curve(bezier.name, {
type = "spring",
-- If all the parameters are empty make a spring with the values from the wiki
mass = bezier.mass or 1,
stiffness = bezier.stiffness or 70,
dampening = bezier.dampening or 10,
})
else
-- You fucked something up
hl.notification.create({ text = "invalid curve generated", icon = "warning", timeout = 8000 })
end
end
local animations = {
-- Default animation
{ leaf = "global", speed = 5, spring = "mediumSpring" },
-- Window animations
{ leaf = "windows", speed = 2, spring = "mediumSpring", style = "slide right" },
{ leaf = "windowsOut", speed = 2, bezier = "heavyOvershoot", style = "popin 30%" },
-- Fade
{ leaf = "fade", speed = 2, bezier = "smoothIn" },
-- Workspaces and Special
{ leaf = "workspaces", speed = 2, bezier = "heavyOvershoot", style = "slidefade 20%" },
{ leaf = "specialWorkspace", speed = 5, spring = "mediumSpring", style = "slidefadevert -80%" },
}
-- For every entry in the animation table
for _, anim in ipairs(animations) do
-- If there is a bezier param
if anim.bezier then
hl.animation({
leaf = anim.leaf,
enabled = true,
speed = anim.speed,
bezier = anim.bezier or "",
style = anim.style or "",
})
elseif anim.spring then
-- Make a spring instead bcs apparently they're different idk
hl.animation({
leaf = anim.leaf,
enabled = true,
speed = anim.speed,
spring = anim.spring or "",
style = anim.style or "",
})
end
end

View File

@@ -1,24 +1,33 @@
hl.config({
input = {
kb_layout = "gb",
follow_mouse = 1,
kb_layout = "gb", -- Goddamn kier starmer
follow_mouse = 1, -- Moving to a window will focus it
touchpad = {
natural_scroll = true,
disable_while_typing = true,
natural_scroll = true, -- Better scrolling
disable_while_typing = true, -- Sanity
},
sensitivity = -0.3,
force_no_accel = false,
sensitivity = -0.3, -- DPI is too high ffs
force_no_accel = false, -- I love mouse acceleration
tablet = {
left_handed = true,
output = "current",
left_handed = true, -- Top 10 disabilities
output = "current", -- Make the tablet usable
},
},
cursor = {
inactive_timeout = 2,
warp_on_change_workspace = 1,
hide_on_key_press = true,
warp_on_toggle_special = 1,
inactive_timeout = 2, -- Hide white thing on the screen
hide_on_key_press = true, -- Hide white thing when typing
warp_on_change_workspace = 1, -- Make it go to workspaces
warp_on_toggle_special = 1, -- Go to special workspaces too
persistent_warps = true, -- Go back to where it was when I warp
},
})
if Hostname == "mobile02" then
hl.config({
input = { -- If on laptop make caps the escape key but make it be capslock when shift caps is pressed
kb_options = "caps:escape_shifted_capslock",
},
})
end