AddLabelModal

package
v1.5.0 Latest Latest
Warning

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

Go to latest
Published: Jan 6, 2022 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AddLabelModal

type AddLabelModal struct {
	*cptype.SDK
	Ctx context.Context
	base.DefaultProvider
	Type       string                `json:"type,omitempty"`
	Props      Props                 `json:"props,omitempty"`
	State      State                 `json:"state,omitempty"`
	Operations map[string]Operations `json:"operations,omitempty"`
}

func (*AddLabelModal) GetState

func (alm *AddLabelModal) GetState()

func (*AddLabelModal) Init

func (alm *AddLabelModal) Init(ctx servicehub.Context) error

func (*AddLabelModal) Render

func (*AddLabelModal) SetComponentValue

func (alm *AddLabelModal) SetComponentValue(c *cptype.Component) error

SetComponentValue mapping properties to Component

type ComponentProps

type ComponentProps struct {
	Options []Option `json:"options,omitempty"`
}

type Fields

type Fields struct {
	Key            string         `json:"key,omitempty"`
	ComponentProps ComponentProps `json:"componentProps,omitempty"`
	Label          string         `json:"label,omitempty"`
	Component      string         `json:"component,omitempty"`
	Rules          Rules          `json:"rules,omitempty"`
	Required       bool           `json:"required,omitempty"`
	RemoveWhen     [][]RemoveWhen `json:"removeWhen,omitempty"`
}

type Operations

type Operations struct {
	Key    string `json:"key,omitempty"`
	Reload bool   `json:"reload,omitempty"`
}

type Option

type Option struct {
	Name     string   `json:"name,omitempty"`
	Value    string   `json:"value,omitempty"`
	Children []Option `json:"children,omitempty"`
}

type Props

type Props struct {
	Fields []Fields `json:"fields,omitempty"`
	Title  string   `json:"title,omitempty"`
}

type RemoveWhen

type RemoveWhen struct {
	Field    string `json:"field,omitempty"`
	Operator string `json:"operator,omitempty"`
	Value    string `json:"value,omitempty"`
}

type Rules

type Rules struct {
	Msg     string `json:"msg,omitempty"`
	Pattern string `json:"pattern,omitempty"`
}

type State

type State struct {
	FormData map[string]string `json:"formData,omitempty"`
	Visible  bool              `json:"visible"`
}

Jump to

Keyboard shortcuts

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