New

We just released a new plugin bundle: Struninn - Elementor Plugins Bundle! We'll be having a discount price for just a few days, so hurry up and check it out!

Our Envato Profile

Documentation

Struninn – Elementor Widgets

wordpress

shortcodes

elementor

react

Stream Plugin

Template Functions

The plugin provides template functions for the following widgets:

Channel Subscribe Button

Syntax

struninntwitch_template_channel_subscribe_button( array $args = [] )

Parameters

$args
(array) (Optional) Arguments to modify template output.

$additional_wrapper_classes
(array) (Optional) Additional classes for the wrapper.

$text
(string) (Optional) Button text.
Default value: ‘Subscribe!’

$before_text
(string) (Optional)
Content to insert before button text.

$after_text
(string) (Optional)
Content to insert after button text.

$href
(string) (Optional)
Button link URL.

$target
(string) (Optional)
Button target.
Default value: ‘_blank’

$styles
(string) (Optional)
Additional inline styles for the wrapper.

Example

$args = [
  'text'                       => __('Subscribe to my channel!', 'text_domain'),
  'additional_wrapper_classes' => ['custom-class-1', 'custom-class-2']
];

struninntwitch_template_channel_subscribe_button($args);

Channel Videos

Syntax

struninntwitch_template_channel_videos( array $args = [] )

Parameters

$args
(array) (Optional) Arguments to modify template output.

$additional_wrapper_classes
(array) (Optional) Additional classes for the wrapper.

$first
(int) (Optional) Amount of videos to display.
Default value: 1

$type
(string) (Optional) Type of videos to display, one of: ‘all’, ‘upload’, ‘archive’, ‘highlight’.
Default value: ‘archive’

$hide_more_button
(bool) (Optional)
True to hide more button.
Default value: false

$styles
(string) (Optional)
Additional inline styles for the wrapper.

Example

$args = [
  'first'            => 4,
  'type'             => 'upload',
  'hide_more_button' => true
];

struninntwitch_template_channel_videos($args);

Channel Stream

Syntax

struninntwitch_template_channel_stream( array $args = [] )

Parameters

$args
(array) (Optional) Arguments to modify template output.

$additional_wrapper_classes
(array) (Optional) Additional classes for the wrapper.

$theme
(string) (Optional)
Stream player theme, one of: ‘dark’, ‘light’.
Default value: ‘dark’

$muted
(bool) (Optional)
True to mute the stream.
Default value: true

$autoplay
(bool) (Optional)
True to autoplay the stream.
Default value: true

$chat
(bool) (Optional)
True to display stream chat.
Default value: true

$styles
(string) (Optional)
Additional inline styles for the wrapper.

Example

$args = [
  'autoplay' => false,
  'chat'     => false
];

struninntwitch_template_channel_stream($args);