The hardware and bandwidth for this mirror is donated by dogado GmbH, the Webhosting and Full Service-Cloud Provider. Check out our Wordpress Tutorial.
If you wish to report a bug, or if you are interested in having us mirror your free-software or open-source project, please feel free to contact us at mirror[@]dogado.de.

Toolbar Items

library(blockr.dag)

The toolbar provides quick access to common graph operations.

Available Actions

The toolbar includes several default operations:

Creating Toolbar Items

Toolbar items are declared via new_toolbar_item():

# Toolbar item
item <- new_toolbar_item(
  id = "custom_tool",
  icon = "icon-custom",
  js = "console.log('Custom tool clicked')",
  action = function(board, update, ...) {
    # Server-side logic
  }
)

js can be a string representing a JavaScript function or an R function that takes the namespace ns as input and returns a string:

function(ns) {
  sprintf(
    "(value, target, current) => {
      Shiny.setInputValue('%s', true, {priority: 'event'});
    }",
    ns("add_block")
  )
}

Any new item has to go inside toolbar_items.dag_extension for registration:

toolbar_items.dag_extension <- function(x) {
  list(
    item
  )

These binaries (installable software) and packages are in development.
They may not be fully stable and should be used with caution. We make no claims about them.
Health stats visible at Monitor.