layout

package
v0.0.0-...-e4b31ca Latest Latest
Warning

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

Go to latest
Published: Oct 23, 2019 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	DragInterval int

	LayoutClass string
	GutterClass string
	GutterSize  int

	Sizes []Size

	Type bool // true - horizontal, false - vertical

	OnStart Event
	OnStop  Event // runs before Element recreating
	OnMove  MoveEvent
	// contains filtered or unexported fields
}

Config layout config structure

func (Config) Init

func (config Config) Init() gas.DynamicComponent

Init generate resizable layout component

type Element

type Element struct {
	E     *gas.E
	Index int
}

type Event

type Event func(first, second Element, _gutter *dom.Element) (stopIt bool, err error)

type MoveEvent

type MoveEvent func(first, second Element, _gutter *dom.Element, offset float64) (stopIt bool, err error)

type Size

type Size struct {
	Min   float64
	Max   float64
	Start float64
	// contains filtered or unexported fields
}

Size layout item size info

Jump to

Keyboard shortcuts

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