downloadbutton

package
v0.0.0-...-a5a65f0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 30, 2017 License: Apache-2.0 Imports: 6 Imported by: 4

Documentation

Overview

Package downloadbutton provides a Button element that is used in the sidebar of the web UI, to download as a zip file all selected files.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New

func New(key string, config map[string]string, cbs *Callbacks) react.Element

New returns the button element. It should be used as the entry point, to create the needed React element.

key is the id for when the button is in a list, see https://facebook.github.io/react/docs/lists-and-keys.html

config is the web UI config that was fetched from the server.

cbs is a wrapper around the callback functions required by this component.

Types

type Callbacks

type Callbacks struct {

	// GetSelection returns the list of files (blobRefs) selected
	// for downloading.
	GetSelection func() []string `js:"getSelection"`
	// contains filtered or unexported fields
}

Callbacks defines the callbacks that must be provided when creating a DownloadItemsBtn instance.

type DownloadItemsBtnDef

type DownloadItemsBtnDef struct {
	react.ComponentDef
}

DownloadItemsBtnDef is the definition for the button, that Renders as a React Button.

func (DownloadItemsBtnDef) OnClick

func (DownloadItemsBtnDef) Props

Props is an auto-generated proxy to the current props of DownloadItemsBtn

func (DownloadItemsBtnDef) Render

func (d DownloadItemsBtnDef) Render() react.Element

func (DownloadItemsBtnDef) ShouldComponentUpdateIntf

func (d DownloadItemsBtnDef) ShouldComponentUpdateIntf(nextProps react.Props, prevState, nextState react.State) bool

type DownloadItemsBtnElem

type DownloadItemsBtnElem struct {
	react.Element
}

type DownloadItemsBtnProps

type DownloadItemsBtnProps struct {
	// Key is the id for when the button is in a list, see
	// https://facebook.github.io/react/docs/lists-and-keys.html
	Key string

	*Callbacks
	// contains filtered or unexported fields
}

func (DownloadItemsBtnProps) EqualsIntf

func (d DownloadItemsBtnProps) EqualsIntf(val react.Props) bool

func (DownloadItemsBtnProps) IsProps

func (d DownloadItemsBtnProps) IsProps()

IsProps is an auto-generated definition so that DownloadItemsBtnProps implements the myitcv.io/react.Props interface.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL