Remove register and update examples

This commit is contained in:
Insality
2024-11-21 00:28:53 +02:00
parent 4ef65579a6
commit bc0ada7098
44 changed files with 78 additions and 668 deletions

View File

@@ -43,8 +43,6 @@ local const = require("druid.const")
local utf8_lua = require("druid.system.utf8")
local utf8 = utf8 or utf8_lua
local input = require("druid.extended.input")
---@class druid.rich_input: druid.base_component
---@field root node
---@field input druid.input
@@ -209,7 +207,7 @@ function M:init(template, nodes)
self.is_lshift = false
self.is_lctrl = false
self.input = self.druid:new(input, "button", "input_text")
self.input = self.druid:new_input("button", "input_text")
self.is_button_input_enabled = gui.is_enabled(self.input.button.node)
self.cursor = self:get_node("cursor_node")

View File

@@ -667,7 +667,7 @@ end
local timer_component = require("druid.extended.timer")
---Create Timer component
---@param node string|node Gui text node
---@param seconds_from number Start timer value in seconds
---@param seconds_from number|nil Start timer value in seconds
---@param seconds_to number|nil End timer value in seconds
---@param callback function|nil Function on timer end
---@return druid.timer Timer component
@@ -690,7 +690,7 @@ end
local layout = require("druid.extended.layout")
---Create Layout component
---@param node string|node The_node id or gui.get_node(node_id).
---@param mode string vertical|horizontal|horizontal_wrap
---@param mode string|nil vertical|horizontal|horizontal_wrap. Default: horizontal
---@return druid.layout Layout component
function M:new_layout(node, mode)
return self:new(layout, node, mode)