class Action extends StaticAction implements Arrayable (View source)

Traits

Constants

BADGE_VIEW

BUTTON_VIEW

GROUPED_VIEW

ICON_BUTTON_VIEW

LINK_VIEW

Properties

protected string $evaluationIdentifier from  EvaluatesClosures
static protected Closure>> $macros from  Macroable
protected string $view from  ViewComponent
protected string|Closure|null $defaultView from  ViewComponent
protected array<string,mixed> $viewData from  ViewComponent
protected string $viewIdentifier
protected ActionGroup|null $group from  BelongsToGroup
protected bool|Closure $isDisabled from  CanBeDisabled
protected mixed $authorization from  CanBeHidden
protected bool|Closure $isHidden from  CanBeHidden
protected bool|Closure $isVisible from  CanBeHidden
protected string|Closure|null $labeledFrom from  CanBeLabeledFrom
protected bool|Closure $isOutlined from  CanBeOutlined
protected string|null $parentActionCallLivewireClickHandler from  CanCallParentAction
protected bool|Closure $shouldClose from  CanClose
protected string|Closure|null $event from  CanDispatchEvent
protected array $eventData from  CanDispatchEvent
protected string|bool $dispatchDirection from  CanDispatchEvent
protected string|null $dispatchToComponent from  CanDispatchEvent
protected bool|Closure $shouldOpenUrlInNewTab from  CanOpenUrl
protected string|Closure|null $url from  CanOpenUrl
protected bool $canSubmitForm from  CanSubmitForm
protected string|null $formToSubmit from  CanSubmitForm
protected string|null $formId from  CanSubmitForm
protected Closure|string|null $action from  HasAction
protected bool|Closure|null $isLivewireClickHandlerEnabled from  HasAction
protected array<string,mixed> $arguments from  HasArguments
protected string|Closure|null $groupedIcon from  HasGroupedIcon
protected string $keyBindings from  HasKeyBindings
protected Htmlable|Closure|null $label from  HasLabel
protected bool|Closure $isLabelHidden from  HasLabel
protected bool $shouldTranslateLabel from  HasLabel
protected string|null $name from  HasName
protected ActionSize|string|Closure|null $defaultSize from  HasSize
protected ActionSize|string|Closure|null $size from  HasSize
protected string|Closure|null $tooltip from  HasTooltip
protected string|int|float|Closure|null $badge from  HasBadge
protected string $badgeColor from  HasBadge
protected string|Closure|null $badgeIcon from  HasBadge
protected IconPosition|string|Closure|null $badgeIconPosition from  HasBadge
protected string $color from  HasColor
protected string $defaultColor from  HasColor
protected array $extraAttributes from  HasExtraAttributes
protected Htmlable|Closure|null $icon from  HasIcon
protected IconPosition|string|Closure|null $iconPosition from  HasIcon
protected IconSize|string|Closure|null $iconSize from  HasIcon
protected string|null $livewireTarget from  StaticAction
protected string|Closure|null $alpineClickHandler from  StaticAction
protected bool|Closure $shouldMarkAsRead
protected bool|Closure $shouldMarkAsUnread

Methods

static mixed
configureUsing(Closure $modifyUsing, Closure|null $during = null, bool $isImportant = false)

No description

configure()

No description

void
setUp()

No description

mixed
evaluate(mixed $value, array $namedInjections = [], array $typedInjections = [])

No description

mixed
resolveClosureDependencyForEvaluation(ReflectionParameter $parameter, array $namedInjections, array $typedInjections)

No description

array
resolveDefaultClosureDependencyForEvaluationByName(string $parameterName)

No description

array
resolveDefaultClosureDependencyForEvaluationByType(string $parameterType)

No description

string|null
static void
macro(string $name, callable $macro)

No description

static void
mixin(object $mixin, bool $replace = true)

No description

static void
flushMacros()

No description

static mixed
__callStatic(string $method, array $parameters)

No description

mixed
__call(string $method, array $parameters)

No description

static callable|null
getMacro(string $method)

No description

view(string|null $view, array $viewData = [])

No description

defaultView(string|Closure|null $view)

No description

array
extractPublicMethods()

No description

viewData(array $data)

No description

string
getView()

No description

string|null
getDefaultView()

No description

string
toHtml()

No description

View
render()

No description

group(ActionGroup|null $group)

No description

ActionGroup|null
getGroup()

No description

ActionGroup|null
getRootGroup()

No description

disabled(bool|Closure $condition = true)

No description

bool
isDisabled()

No description

bool
isEnabled()

No description

authorize(mixed $abilities, Model|string|array|null $arguments = null)

No description

authorizeAny(string|BackedEnum|array $abilities, Model|array|null $arguments = null)

No description

array
parseAuthorizationArguments(array $arguments)

No description

hidden(bool|Closure $condition = true)

No description

visible(bool|Closure $condition = true)

No description

bool
isAuthorized()

No description

bool
isHidden()

No description

bool
isHiddenInGroup()

No description

bool
isVisible()

No description

labeledFrom(string|Closure|null $breakpoint = null)

No description

string|null
getLabeledFromBreakpoint()

No description

outlined(bool|Closure $condition = true)

No description

bool
isOutlined()

No description

callParent(string|null $handler)

No description

close(bool|Closure $condition = true)

No description

from  CanClose
bool
shouldClose()

No description

from  CanClose
dispatch(string|Closure|null $event, array|Closure $data = [])

No description

dispatchSelf(string|Closure|null $event, array|Closure $data = [])

No description

dispatchTo(string $component, string|Closure|null $event, array|Closure $data = [])

No description

emit(string|Closure|null $event, array|Closure $data = []) deprecated

No description

emitSelf(string|Closure|null $event, array|Closure $data = []) deprecated

No description

emitTo(string $component, string|Closure|null $event, array|Closure $data = []) deprecated

No description

string|null
getEvent()

No description

eventData(array|Closure $data)

No description

array
getEventData()

No description

string|bool
getDispatchDirection()

No description

string|null
getDispatchToComponent()

No description

openUrlInNewTab(bool|Closure $condition = true)

No description

url(string|Closure|null $url, bool|Closure $shouldOpenInNewTab = false)

No description

string|null
getUrl()

No description

bool
shouldOpenUrlInNewTab()

No description

submit(string|null $form)

No description

bool
canSubmitForm()

No description

string|null
getFormToSubmit()

No description

formId(string|null $id)

No description

string|null
getFormId()

No description

action(Closure|string|null $action)

No description

livewireClickHandlerEnabled(bool|Closure|null $condition = true)

No description

Closure|null
getActionFunction()

No description

bool
arguments(array|null $arguments)

No description

mergeArguments(array $arguments)

No description

array
getArguments()

No description

resetArguments()

No description

bool
hasArguments()

No description

groupedIcon(string|Closure|null $icon)

No description

string|null
getGroupedIcon()

No description

keyBindings(string|array|Closure|null $bindings)

No description

array|null
getKeyBindings()

No description

disableLabel(bool|Closure $condition = true) deprecated

No description

from  HasLabel
hiddenLabel(bool|Closure $condition = true)

No description

from  HasLabel
label(Htmlable|Closure|null $label)

No description

from  HasLabel
translateLabel(bool $shouldTranslateLabel = true)

No description

from  HasLabel
Htmlable|null
getLabel()

No description

from  HasLabel
bool
isLabelHidden()

No description

from  HasLabel
name(string|null $name)

No description

from  HasName
string|null
getName()

No description

from  HasName
defaultSize(ActionSize|string|Closure|null $size)

No description

from  HasSize
size(ActionSize|string|Closure|null $size)

No description

from  HasSize
ActionSize|string|null
getDefaultSize()

No description

from  HasSize
ActionSize|string|null
getSize()

No description

from  HasSize
tooltip(string|Closure|null $tooltip)

No description

string|null
getTooltip()

No description

badge(string|int|float|Closure|null $badge = null)

No description

from  HasBadge
indicator(string|int|float|Closure|null $indicator) deprecated

No description

from  HasBadge
badgeColor(string|array|Closure|null $color)

No description

from  HasBadge
badgeIcon(string|Closure|null $icon)

No description

from  HasBadge
badgeIconPosition(IconPosition|string|Closure|null $position)

No description

from  HasBadge
indicatorColor(string|array|Closure|null $color) deprecated

No description

from  HasBadge
string|int|float|null
getBadge()

No description

from  HasBadge
string|array|null
getBadgeColor()

No description

from  HasBadge
string|null
getBadgeIcon()

No description

from  HasBadge
IconPosition|string
getBadgeIconPosition()

No description

from  HasBadge
color(string|array|Closure|null $color)

No description

from  HasColor
defaultColor(string|array|Closure|null $color)

No description

from  HasColor
string|array|null
getColor()

No description

from  HasColor
extraAttributes(array|Closure $attributes, bool $merge = false)

No description

array
getExtraAttributes()

No description

ComponentAttributeBag
getExtraAttributeBag()

No description

icon(Htmlable|Closure|null $icon)

No description

from  HasIcon
iconPosition(IconPosition|string|Closure|null $position)

No description

from  HasIcon
iconSize(IconSize|string|Closure|null $size)

No description

from  HasIcon
Htmlable|null
getIcon()

No description

from  HasIcon
IconPosition|string
getIconPosition()

No description

from  HasIcon
IconSize|string|null
getIconSize()

No description

from  HasIcon
__construct(string|null $name)

No description

static StaticAction
make(string|null $name = null)

No description

bool
isBadge()

No description

button()

No description

bool
isButton()

No description

grouped()

No description

iconButton()

No description

bool
isIconButton()

No description

link()

No description

bool
isLink()

No description

alpineClickHandler(string|Closure|null $handler)

No description

static string|null
getDefaultName()

No description

string|null
getLivewireClickHandler()

No description

string|null
getLivewireEventClickHandler()

No description

string|null
getAlpineClickHandler()

No description

livewireTarget(string|null $target)

No description

string|null
getLivewireTarget()

No description

withAttributes(array $attributes) deprecated

No description

markAsRead(bool|Closure $condition = true)

No description

markAsUnread(bool|Closure $condition = true)

No description

array
toArray()

No description

static Action
fromArray(array $data)

No description

static bool
isViewSafe(string $view)

No description

bool
shouldMarkAsRead()

No description

bool
shouldMarkAsUnread()

No description

Details

static mixed configureUsing(Closure $modifyUsing, Closure|null $during = null, bool $isImportant = false)

No description

Parameters

Closure $modifyUsing
Closure|null $during
bool $isImportant

Return Value

mixed

Configurable configure()

No description

Return Value

Configurable

protected void setUp()

No description

Return Value

void

mixed evaluate(mixed $value, array $namedInjections = [], array $typedInjections = [])

No description

Parameters

mixed $value
array $namedInjections
array $typedInjections

Return Value

mixed

protected mixed resolveClosureDependencyForEvaluation(ReflectionParameter $parameter, array $namedInjections, array $typedInjections)

No description

Parameters

ReflectionParameter $parameter
array $namedInjections
array $typedInjections

Return Value

mixed

protected array resolveDefaultClosureDependencyForEvaluationByName(string $parameterName)

No description

Parameters

string $parameterName

Return Value

array

protected array resolveDefaultClosureDependencyForEvaluationByType(string $parameterType)

No description

Parameters

string $parameterType

Return Value

array

protected string|null getTypedReflectionParameterClassName(ReflectionParameter $parameter)

No description

Parameters

ReflectionParameter $parameter

Return Value

string|null

static void macro(string $name, callable $macro)

No description

Parameters

string $name
callable $macro

Return Value

void

static void mixin(object $mixin, bool $replace = true)

No description

Parameters

object $mixin
bool $replace

Return Value

void

static void flushMacros()

No description

Return Value

void

static mixed __callStatic(string $method, array $parameters)

No description

Parameters

string $method
array $parameters

Return Value

mixed

mixed __call(string $method, array $parameters)

No description

Parameters

string $method
array $parameters

Return Value

mixed

static protected callable|null getMacro(string $method)

No description

Parameters

string $method

Return Value

callable|null

ViewComponent view(string|null $view, array $viewData = [])

No description

Parameters

string|null $view
array $viewData

Return Value

ViewComponent

ViewComponent defaultView(string|Closure|null $view)

No description

Parameters

string|Closure|null $view

Return Value

ViewComponent

protected array extractPublicMethods()

No description

Return Value

array

ViewComponent viewData(array $data)

No description

Parameters

array $data

Return Value

ViewComponent

string getView()

No description

Return Value

string

string|null getDefaultView()

No description

Return Value

string|null

string toHtml()

No description

Return Value

string

View render()

No description

Return Value

View

BelongsToGroup group(ActionGroup|null $group)

No description

Parameters

ActionGroup|null $group

Return Value

BelongsToGroup

ActionGroup|null getGroup()

No description

Return Value

ActionGroup|null

ActionGroup|null getRootGroup()

No description

Return Value

ActionGroup|null

CanBeDisabled disabled(bool|Closure $condition = true)

No description

Parameters

bool|Closure $condition

Return Value

CanBeDisabled

bool isDisabled()

No description

Return Value

bool

bool isEnabled()

No description

Return Value

bool

CanBeHidden authorize(mixed $abilities, Model|string|array|null $arguments = null)

No description

Parameters

mixed $abilities
Model|string|array|null $arguments

Return Value

CanBeHidden

CanBeHidden authorizeAny(string|BackedEnum|array $abilities, Model|array|null $arguments = null)

No description

Parameters

string|BackedEnum|array $abilities
Model|array|null $arguments

Return Value

CanBeHidden

protected array parseAuthorizationArguments(array $arguments)

No description

Parameters

array $arguments

Return Value

array

CanBeHidden hidden(bool|Closure $condition = true)

No description

Parameters

bool|Closure $condition

Return Value

CanBeHidden

CanBeHidden visible(bool|Closure $condition = true)

No description

Parameters

bool|Closure $condition

Return Value

CanBeHidden

bool isAuthorized()

No description

Return Value

bool

bool isHidden()

No description

Return Value

bool

bool isHiddenInGroup()

No description

Return Value

bool

bool isVisible()

No description

Return Value

bool

CanBeLabeledFrom labeledFrom(string|Closure|null $breakpoint = null)

No description

Parameters

string|Closure|null $breakpoint

Return Value

CanBeLabeledFrom

string|null getLabeledFromBreakpoint()

No description

Return Value

string|null

CanBeOutlined outlined(bool|Closure $condition = true)

No description

Parameters

bool|Closure $condition

Return Value

CanBeOutlined

bool isOutlined()

No description

Return Value

bool

CanCallParentAction callParent(string|null $handler)

No description

Parameters

string|null $handler

Return Value

CanCallParentAction

string|null getParentActionCallLivewireClickHandler()

No description

Return Value

string|null

CanClose close(bool|Closure $condition = true)

No description

Parameters

bool|Closure $condition

Return Value

CanClose

bool shouldClose()

No description

Return Value

bool

CanDispatchEvent dispatch(string|Closure|null $event, array|Closure $data = [])

No description

Parameters

string|Closure|null $event
array|Closure $data

Return Value

CanDispatchEvent

CanDispatchEvent dispatchSelf(string|Closure|null $event, array|Closure $data = [])

No description

Parameters

string|Closure|null $event
array|Closure $data

Return Value

CanDispatchEvent

CanDispatchEvent dispatchTo(string $component, string|Closure|null $event, array|Closure $data = [])

No description

Parameters

string $component
string|Closure|null $event
array|Closure $data

Return Value

CanDispatchEvent

CanDispatchEvent emit(string|Closure|null $event, array|Closure $data = []) deprecated

deprecated Use `dispatch()` instead.

No description

Parameters

string|Closure|null $event
array|Closure $data

Return Value

CanDispatchEvent

CanDispatchEvent emitSelf(string|Closure|null $event, array|Closure $data = []) deprecated

deprecated Use `dispatchSelf()` instead.

No description

Parameters

string|Closure|null $event
array|Closure $data

Return Value

CanDispatchEvent

CanDispatchEvent emitTo(string $component, string|Closure|null $event, array|Closure $data = []) deprecated

deprecated Use `dispatchTo()` instead.

No description

Parameters

string $component
string|Closure|null $event
array|Closure $data

Return Value

CanDispatchEvent

string|null getEvent()

No description

Return Value

string|null

CanDispatchEvent eventData(array|Closure $data)

No description

Parameters

array|Closure $data

Return Value

CanDispatchEvent

array getEventData()

No description

Return Value

array

string|bool getDispatchDirection()

No description

Return Value

string|bool

string|null getDispatchToComponent()

No description

Return Value

string|null

CanOpenUrl openUrlInNewTab(bool|Closure $condition = true)

No description

Parameters

bool|Closure $condition

Return Value

CanOpenUrl

CanOpenUrl url(string|Closure|null $url, bool|Closure $shouldOpenInNewTab = false)

No description

Parameters

string|Closure|null $url
bool|Closure $shouldOpenInNewTab

Return Value

CanOpenUrl

string|null getUrl()

No description

Return Value

string|null

bool shouldOpenUrlInNewTab()

No description

Return Value

bool

CanSubmitForm submit(string|null $form)

No description

Parameters

string|null $form

Return Value

CanSubmitForm

bool canSubmitForm()

No description

Return Value

bool

string|null getFormToSubmit()

No description

Return Value

string|null

CanSubmitForm formId(string|null $id)

No description

Parameters

string|null $id

Return Value

CanSubmitForm

string|null getFormId()

No description

Return Value

string|null

HasAction action(Closure|string|null $action)

No description

Parameters

Closure|string|null $action

Return Value

HasAction

HasAction livewireClickHandlerEnabled(bool|Closure|null $condition = true)

No description

Parameters

bool|Closure|null $condition

Return Value

HasAction

Closure|null getActionFunction()

No description

Return Value

Closure|null

bool isLivewireClickHandlerEnabled()

No description

Return Value

bool

HasArguments arguments(array|null $arguments)

No description

Parameters

array|null $arguments

Return Value

HasArguments

HasArguments mergeArguments(array $arguments)

No description

Parameters

array $arguments

Return Value

HasArguments

array getArguments()

No description

Return Value

array

HasArguments resetArguments()

No description

Return Value

HasArguments

bool hasArguments()

No description

Return Value

bool

HasGroupedIcon groupedIcon(string|Closure|null $icon)

No description

Parameters

string|Closure|null $icon

Return Value

HasGroupedIcon

string|null getGroupedIcon()

No description

Return Value

string|null

HasKeyBindings keyBindings(string|array|Closure|null $bindings)

No description

Parameters

string|array|Closure|null $bindings

Return Value

HasKeyBindings

array|null getKeyBindings()

No description

Return Value

array|null

| null

HasLabel disableLabel(bool|Closure $condition = true) deprecated

deprecated Use `hiddenLabel()` instead.

No description

Parameters

bool|Closure $condition

Return Value

HasLabel

HasLabel hiddenLabel(bool|Closure $condition = true)

No description

Parameters

bool|Closure $condition

Return Value

HasLabel

HasLabel label(Htmlable|Closure|null $label)

No description

Parameters

Htmlable|Closure|null $label

Return Value

HasLabel

HasLabel translateLabel(bool $shouldTranslateLabel = true)

No description

Parameters

bool $shouldTranslateLabel

Return Value

HasLabel

Htmlable|null getLabel()

No description

Return Value

Htmlable|null

bool isLabelHidden()

No description

Return Value

bool

HasName name(string|null $name)

No description

Parameters

string|null $name

Return Value

HasName

string|null getName()

No description

Return Value

string|null

HasSize defaultSize(ActionSize|string|Closure|null $size)

No description

Parameters

ActionSize|string|Closure|null $size

Return Value

HasSize

HasSize size(ActionSize|string|Closure|null $size)

No description

Parameters

ActionSize|string|Closure|null $size

Return Value

HasSize

ActionSize|string|null getDefaultSize()

No description

Return Value

ActionSize|string|null

ActionSize|string|null getSize()

No description

Return Value

ActionSize|string|null

HasTooltip tooltip(string|Closure|null $tooltip)

No description

Parameters

string|Closure|null $tooltip

Return Value

HasTooltip

string|null getTooltip()

No description

Return Value

string|null

HasBadge badge(string|int|float|Closure|null $badge = null)

No description

Parameters

string|int|float|Closure|null $badge

Return Value

HasBadge

HasBadge indicator(string|int|float|Closure|null $indicator) deprecated

deprecated Use `badge()` instead.

No description

Parameters

string|int|float|Closure|null $indicator

Return Value

HasBadge

HasBadge badgeColor(string|array|Closure|null $color)

No description

Parameters

string|array|Closure|null $color

Return Value

HasBadge

HasBadge badgeIcon(string|Closure|null $icon)

No description

Parameters

string|Closure|null $icon

Return Value

HasBadge

HasBadge badgeIconPosition(IconPosition|string|Closure|null $position)

No description

Parameters

IconPosition|string|Closure|null $position

Return Value

HasBadge

HasBadge indicatorColor(string|array|Closure|null $color) deprecated

deprecated Use `badgeColor()` instead.

No description

Parameters

string|array|Closure|null $color

Return Value

HasBadge

string|int|float|null getBadge()

No description

Return Value

string|int|float|null

string|array|null getBadgeColor()

No description

Return Value

string|array|null

| array{50: string, 100: string, 200: string, 300: string, 400: string, 500: string, 600: string, 700: string, 800: string, 900: string, 950: string} | null

string|null getBadgeIcon()

No description

Return Value

string|null

IconPosition|string getBadgeIconPosition()

No description

Return Value

IconPosition|string

HasColor color(string|array|Closure|null $color)

No description

Parameters

string|array|Closure|null $color

Return Value

HasColor

HasColor defaultColor(string|array|Closure|null $color)

No description

Parameters

string|array|Closure|null $color

Return Value

HasColor

string|array|null getColor()

No description

Return Value

string|array|null

| array{50: string, 100: string, 200: string, 300: string, 400: string, 500: string, 600: string, 700: string, 800: string, 900: string, 950: string} | null

HasExtraAttributes extraAttributes(array|Closure $attributes, bool $merge = false)

No description

Parameters

array|Closure $attributes
bool $merge

Return Value

HasExtraAttributes

array getExtraAttributes()

No description

Return Value

array

ComponentAttributeBag getExtraAttributeBag()

No description

Return Value

ComponentAttributeBag

HasIcon icon(Htmlable|Closure|null $icon)

No description

Parameters

Htmlable|Closure|null $icon

Return Value

HasIcon

HasIcon iconPosition(IconPosition|string|Closure|null $position)

No description

Parameters

IconPosition|string|Closure|null $position

Return Value

HasIcon

HasIcon iconSize(IconSize|string|Closure|null $size)

No description

Parameters

IconSize|string|Closure|null $size

Return Value

HasIcon

Htmlable|null getIcon()

No description

Return Value

Htmlable|null

IconPosition|string getIconPosition()

No description

Return Value

IconPosition|string

IconSize|string|null getIconSize()

No description

Return Value

IconSize|string|null

final __construct(string|null $name)

No description

Parameters

string|null $name

static StaticAction make(string|null $name = null)

No description

Parameters

string|null $name

Return Value

StaticAction

bool isBadge()

No description

Return Value

bool

StaticAction button()

No description

Return Value

StaticAction

bool isButton()

No description

Return Value

bool

Groupable grouped()

No description

Return Value

Groupable

StaticAction iconButton()

No description

Return Value

StaticAction

bool isIconButton()

No description

Return Value

bool

No description

Return Value

StaticAction

No description

Return Value

bool

StaticAction alpineClickHandler(string|Closure|null $handler)

No description

Parameters

string|Closure|null $handler

Return Value

StaticAction

static string|null getDefaultName()

No description

Return Value

string|null

string|null getLivewireClickHandler()

No description

Return Value

string|null

string|null getLivewireEventClickHandler()

No description

Return Value

string|null

string|null getAlpineClickHandler()

No description

Return Value

string|null

StaticAction livewireTarget(string|null $target)

No description

Parameters

string|null $target

Return Value

StaticAction

string|null getLivewireTarget()

No description

Return Value

string|null

StaticAction withAttributes(array $attributes) deprecated

deprecated Use `extraAttributes()` instead.

No description

Parameters

array $attributes

Return Value

StaticAction

Action markAsRead(bool|Closure $condition = true)

No description

Parameters

bool|Closure $condition

Return Value

Action

Action markAsUnread(bool|Closure $condition = true)

No description

Parameters

bool|Closure $condition

Return Value

Action

array toArray()

No description

Return Value

array

static Action fromArray(array $data)

No description

Parameters

array $data

Return Value

Action

static protected bool isViewSafe(string $view)

No description

Parameters

string $view

Return Value

bool

bool shouldMarkAsRead()

No description

Return Value

bool

bool shouldMarkAsUnread()

No description

Return Value

bool