Package 'shinyDND'

Title: Shiny Drag-n-Drop
Description: Add functionality to create drag and drop div elements in shiny.
Authors: Aaron Hoffer [aut, cre]
Maintainer: Aaron Hoffer <[email protected]>
License: GPL-3
Version: 0.1.1
Built: 2025-02-20 03:29:01 UTC
Source: https://github.com/ayayron/shinydnd

Help Index


dragSetUI

Description

With draggable elements, you may not want to create one at a time, instead creating a set with a common id prefix. This simplifies the process to pass a vector of elements instead of using a loop or apply function to generate

Usage

dragSetUI(id, textval = list(""))

Arguments

id

The div id of the draggable element set

textval

The list with the name for each of the draggable elements

Value

Returns the set of dragable div elements.

Examples

dragSetUI("dragset", list("foo", "bar", "baz"))

dragUI

Description

Create a draggable UI element.

Usage

dragUI(id, ..., style = NULL, class = "dragelement")

Arguments

id

The div id of the element

...

Any list of elements can be passed inside the div element itself to create more complex draggable elements, not just text

style

Add a string with additional css styling not defined by id or class

class

The css class style, uses the standard "dragelement" class that it comes with

Value

dragable div element


dropUI

Description

dropUI

Usage

dropUI(id, style = NULL, class = "dropelement", row_n = 1, col_n = 1)

Arguments

id

The div id of the element

style

The css styling

class

The css class style

row_n

set the number of rows to be used in the vertical selection. Height is proportional to the number of rows.

col_n

set the number of columns to be used in the vertical selection. Width is proportional to the number of columns.

Value

div element with nested elements if vertical is true


ShinyDND: A package for creating drag and drop elements in Shiny.

Description

The ShinyDND package provides three categories of important functions: dragUI, dropUI, and dragSetUI.

ShinyDND functions

The ShinyDND functions ...