( ◞≼☸≽◟ ._ゝ◞≼☸≽◟)zcsdf吖 $this->applyFilter('./element.php', ['path']),
'name' => 'popover',
'title' => 'Popover',
'icon' => $this->applyFilter('images/icon.svg', ['url']),
'iconSmall' => $this->applyFilter('images/iconSmall.svg', ['url']),
'element' => true,
'container' => true,
'width' => 500,
'defaults' => [
'show_title' => true,
'show_meta' => true,
'show_content' => true,
'show_image' => true,
'show_link' => true,
'icon' => 'plus',
'drop_mode' => 'hover',
'drop_position' => 'top-center',
'card_style' => 'default',
'title_element' => 'h3',
'meta_style' => 'meta',
'meta_align' => 'below-title',
'image_card_padding' => true,
'image_svg_color' => 'emphasis',
'link_text' => 'Read more',
'link_style' => 'default',
'margin' => 'default'
],
'placeholder' => [
'children' => [[
'type' => 'popover_item',
'props' => [
'position_x' => 20,
'position_y' => 50
]
], [
'type' => 'popover_item',
'props' => [
'position_x' => 50,
'position_y' => 20
]
], [
'type' => 'popover_item',
'props' => [
'position_x' => 70,
'position_y' => 70
]
]]
],
'templates' => [
'render' => $this->applyFilter('./templates/template.php', ['path']),
'content' => $this->applyFilter('./templates/content.php', ['path'])
],
'fields' => [
'background_image' => [
'label' => 'Image',
'type' => 'image'
],
'background_image_width' => [
'label' => 'Image Width',
'attrs' => [
'placeholder' => 'auto'
],
'enable' => 'background_image'
],
'background_image_height' => [
'label' => 'Image Height',
'attrs' => [
'placeholder' => 'auto'
],
'enable' => 'background_image'
],
'background_image_alt' => [
'label' => 'Image Alt',
'enable' => 'background_image'
],
'content' => [
'label' => 'Items',
'type' => 'content-items',
'item' => 'popover_item',
'media' => [
'type' => 'image',
'item' => [
'title' => 'title',
'image' => 'src'
]
]
],
'show_title' => [
'label' => 'Display',
'type' => 'checkbox',
'text' => 'Show the title'
],
'show_meta' => [
'type' => 'checkbox',
'text' => 'Show the meta text'
],
'show_image' => [
'type' => 'checkbox',
'text' => 'Show the image'
],
'show_content' => [
'type' => 'checkbox',
'text' => 'Show the content'
],
'show_link' => [
'description' => 'Show or hide content fields without the need to delete the content itself.',
'type' => 'checkbox',
'text' => 'Show the link'
],
'drop_mode' => [
'label' => 'Mode',
'description' => 'Display the popover on click or hover.',
'type' => 'select',
'options' => [
'Click' => 'click',
'Hover' => 'hover'
]
],
'drop_position' => [
'label' => 'Position',
'description' => 'Select the popover\'s alignment to its marker. If the popover doesn\'t fit its container, it will flip automatically.',
'type' => 'select',
'options' => [
'Top' => 'top-center',
'Bottom' => 'bottom-center',
'Left' => 'left-center',
'Right' => 'right-center'
]
],
'drop_width' => [
'label' => 'Width',
'description' => 'Enter a width for the popover in pixels.',
'attrs' => [
'placeholder' => '300'
]
],
'card_style' => [
'label' => 'Style',
'description' => 'Select a card style.',
'type' => 'select',
'options' => [
'Default' => 'default',
'Primary' => 'primary',
'Secondary' => 'secondary'
]
],
'card_size' => [
'label' => 'Padding',
'description' => 'Define the card\'s size by selecting the padding between the card and its content.',
'type' => 'select',
'default' => '',
'options' => [
'Small' => 'small',
'Default' => '',
'Large' => 'large'
]
],
'title_style' => [
'label' => 'Style',
'description' => 'Title styles differ in font-size but may also come with a predefined color, size and font.',
'type' => 'select',
'default' => '',
'options' => [
'None' => '',
'Small' => 'heading-small',
'H1' => 'h1',
'H2' => 'h2',
'H3' => 'h3',
'H4' => 'h4',
'H5' => 'h5',
'H6' => 'h6'
],
'enable' => 'show_title'
],
'title_decoration' => [
'label' => 'Decoration',
'description' => 'Decorate the title with a divider, bullet or a line that is vertically centered to the heading.',
'type' => 'select',
'default' => '',
'options' => [
'None' => '',
'Divider' => 'divider',
'Bullet' => 'bullet',
'Line' => 'line'
],
'enable' => 'show_title'
],
'title_font_family' => [
'label' => 'Font Family',
'description' => 'Select an alternative font family.',
'type' => 'select',
'default' => '',
'options' => [
'None' => '',
'Default' => 'default',
'Primary' => 'primary',
'Secondary' => 'secondary',
'Tertiary' => 'tertiary'
],
'enable' => 'show_title'
],
'title_color' => [
'label' => 'Color',
'description' => 'Select the text color. If the Background option is selected, styles that don\'t apply a background image use the primary color instead.',
'type' => 'select',
'default' => '',
'options' => [
'None' => '',
'Muted' => 'muted',
'Emphasis' => 'emphasis',
'Primary' => 'primary',
'Success' => 'success',
'Warning' => 'warning',
'Danger' => 'danger',
'Background' => 'background'
],
'enable' => 'show_title'
],
'title_element' => [
'label' => 'HTML Element',
'description' => 'Choose one of the six heading elements to fit your semantic structure.',
'type' => 'select',
'options' => [
'H1' => 'h1',
'H2' => 'h2',
'H3' => 'h3',
'H4' => 'h4',
'H5' => 'h5',
'H6' => 'h6'
],
'enable' => 'show_title'
],
'title_margin' => [
'label' => 'Margin Top',
'description' => 'Set the top margin. Note that the margin will only apply if the content field immediately follows another content field.',
'type' => 'select',
'default' => '',
'options' => [
'Small' => 'small',
'Default' => '',
'Medium' => 'medium',
'Large' => 'large',
'X-Large' => 'xlarge',
'None' => 'remove'
],
'enable' => 'show_title'
],
'meta_style' => [
'label' => 'Style',
'description' => 'Select a predefined meta text style, including color, size and font-family.',
'type' => 'select',
'options' => [
'None' => '',
'Meta' => 'meta',
'H1' => 'h1',
'H2' => 'h2',
'H3' => 'h3',
'H4' => 'h4',
'H5' => 'h5',
'H6' => 'h6'
],
'enable' => 'show_meta'
],
'meta_color' => [
'label' => 'Color',
'description' => 'Select the text color.',
'type' => 'select',
'default' => '',
'options' => [
'None' => '',
'Muted' => 'muted',
'Emphasis' => 'emphasis',
'Primary' => 'primary',
'Success' => 'success',
'Warning' => 'warning',
'Danger' => 'danger'
],
'enable' => 'show_meta'
],
'meta_align' => [
'label' => 'Alignment',
'description' => 'Align the meta text.',
'type' => 'select',
'options' => [
'Above Title' => 'above-title',
'Below Title' => 'below-title',
'Below Content' => 'below-content'
],
'enable' => 'show_meta'
],
'meta_margin' => [
'label' => 'Margin Top',
'description' => 'Set the top margin. Note that the margin will only apply if the content field immediately follows another content field.',
'type' => 'select',
'default' => '',
'options' => [
'Small' => 'small',
'Default' => '',
'Medium' => 'medium',
'Large' => 'large',
'X-Large' => 'xlarge',
'None' => 'remove'
],
'enable' => 'show_meta'
],
'content_style' => [
'label' => 'Style',
'description' => 'Select a predefined text style, including color, size and font-family.',
'type' => 'select',
'default' => '',
'options' => [
'None' => '',
'Lead' => 'lead'
],
'enable' => 'show_content'
],
'content_margin' => [
'label' => 'Margin Top',
'description' => 'Set the top margin. Note that the margin will only apply if the content field immediately follows another content field.',
'type' => 'select',
'default' => '',
'options' => [
'Small' => 'small',
'Default' => '',
'Medium' => 'medium',
'Large' => 'large',
'X-Large' => 'xlarge',
'None' => 'remove'
],
'enable' => 'show_content'
],
'image_width' => [
'attrs' => [
'placeholder' => 'auto'
],
'enable' => 'show_image'
],
'image_height' => [
'attrs' => [
'placeholder' => 'auto'
],
'enable' => 'show_image'
],
'image_card_padding' => [
'label' => 'Padding',
'description' => 'Attach the image to the drop\'s edge.',
'type' => 'checkbox',
'text' => 'Align image without padding',
'enable' => 'show_image'
],
'image_border' => [
'label' => 'Border',
'description' => 'Select the image\'s border style.',
'type' => 'select',
'default' => '',
'options' => [
'None' => '',
'Rounded' => 'rounded',
'Circle' => 'circle',
'Pill' => 'pill'
],
'enable' => 'show_image && !image_card_padding'
],
'image_svg_inline' => [
'label' => 'Inline SVG',
'description' => 'Inject SVG images into the page markup, so that they can easily be styled with CSS.',
'type' => 'checkbox',
'text' => 'Make SVG stylable with CSS',
'enable' => 'show_image'
],
'image_svg_animate' => [
'type' => 'checkbox',
'text' => 'Animate strokes',
'enable' => 'show_image && image_svg_inline'
],
'image_svg_color' => [
'label' => 'SVG Color',
'description' => 'Select the SVG color. It will only apply to supported elements defined in the SVG.',
'type' => 'select',
'options' => [
'None' => '',
'Muted' => 'muted',
'Emphasis' => 'emphasis',
'Primary' => 'primary',
'Secondary' => 'secondary',
'Success' => 'success',
'Warning' => 'warning',
'Danger' => 'danger'
],
'enable' => 'show_image && image_svg_inline'
],
'link_type' => [
'label' => 'Type',
'description' => 'Show the link as a button or choose between linking just the image and title or the whole item.',
'type' => 'select',
'default' => '',
'options' => [
'Button' => '',
'Title/Image' => 'content',
'Item' => 'element'
],
'enable' => 'show_link'
],
'link_target' => [
'type' => 'checkbox',
'text' => 'Open in a new window',
'enable' => 'show_link'
],
'link_text' => [
'label' => 'Text',
'description' => 'Enter the text for the link.',
'enable' => 'show_link && !link_type'
],
'link_style' => [
'label' => 'Style',
'description' => 'Set the link style.',
'type' => 'select',
'options' => [
'Button Default' => 'default',
'Button Primary' => 'primary',
'Button Secondary' => 'secondary',
'Button Danger' => 'danger',
'Button Text' => 'text',
'Link' => '',
'Link Muted' => 'link-muted',
'Link Text' => 'link-text'
],
'enable' => 'show_link && !link_type'
],
'link_size' => [
'label' => 'Button Size',
'description' => 'Set the button size.',
'type' => 'select',
'default' => '',
'options' => [
'Small' => 'small',
'Default' => '',
'Large' => 'large'
],
'enable' => 'show_link && !link_type && link_style && link_style != \'link-muted\' && link_style != \'link-text\''
],
'link_margin' => [
'label' => 'Margin Top',
'description' => 'Set the top margin. Note that the margin will only apply if the content field immediately follows another content field.',
'type' => 'select',
'default' => '',
'options' => [
'Small' => 'small',
'Default' => '',
'Medium' => 'medium',
'Large' => 'large',
'X-Large' => 'xlarge',
'None' => 'remove'
],
'enable' => 'show_link && !link_type'
],
'position' => $this->get('builder.position'),
'position_left' => $this->get('builder.position_left'),
'position_right' => $this->get('builder.position_right'),
'position_top' => $this->get('builder.position_top'),
'position_bottom' => $this->get('builder.position_bottom'),
'position_z_index' => $this->get('builder.position_z_index'),
'margin' => $this->get('builder.margin'),
'margin_remove_top' => $this->get('builder.margin_remove_top'),
'margin_remove_bottom' => $this->get('builder.margin_remove_bottom'),
'maxwidth' => $this->get('builder.maxwidth'),
'maxwidth_breakpoint' => $this->get('builder.maxwidth_breakpoint'),
'block_align' => $this->get('builder.block_align'),
'block_align_breakpoint' => $this->get('builder.block_align_breakpoint'),
'block_align_fallback' => $this->get('builder.block_align_fallback'),
'text_align' => $this->get('builder.text_align_justify'),
'text_align_breakpoint' => $this->get('builder.text_align_breakpoint'),
'text_align_fallback' => $this->get('builder.text_align_justify_fallback'),
'animation' => $this->get('builder.animation'),
'_parallax_button' => $this->get('builder._parallax_button'),
'visibility' => $this->get('builder.visibility'),
'container_padding_remove' => $this->get('builder.container_padding_remove'),
'name' => $this->get('builder.name'),
'status' => $this->get('builder.status'),
'id' => $this->get('builder.id'),
'class' => $this->get('builder.cls'),
'css' => [
'label' => 'CSS',
'description' => 'Enter your own custom CSS. The following selectors will be prefixed automatically for this element: .el-element, .el-marker, .el-item, .el-title, .el-meta, .el-content, .el-image, .el-link',
'type' => 'editor',
'editor' => 'code',
'mode' => 'css',
'attrs' => [
'debounce' => 500
]
]
],
'fieldset' => [
'default' => [
'type' => 'tabs',
'fields' => [[
'title' => 'Content',
'fields' => ['background_image', [
'description' => 'Setting just one value preserves the original proportions. The image will be resized and cropped automatically, and where possible, high resolution images will be auto-generated.',
'name' => '_background_image_dimension',
'type' => 'grid',
'width' => '1-2',
'fields' => ['background_image_width', 'background_image_height']
], 'background_image_alt', 'content', 'show_title', 'show_meta', 'show_image', 'show_content', 'show_link']
], [
'title' => 'Settings',
'fields' => [[
'label' => 'Popover',
'type' => 'group',
'divider' => true,
'fields' => ['drop_mode', 'drop_position', 'drop_width', 'card_style', 'card_size']
], [
'label' => 'Title',
'type' => 'group',
'divider' => true,
'fields' => ['title_style', 'title_decoration', 'title_font_family', 'title_color', 'title_element', 'title_margin']
], [
'label' => 'Meta',
'type' => 'group',
'divider' => true,
'fields' => ['meta_style', 'meta_color', 'meta_align', 'meta_margin']
], [
'label' => 'Content',
'type' => 'group',
'divider' => true,
'fields' => ['content_style', 'content_margin']
], [
'label' => 'Image',
'type' => 'group',
'divider' => true,
'fields' => [[
'label' => 'Width/Height',
'description' => 'Setting just one value preserves the original proportions. The image will be resized and cropped automatically, and where possible, high resolution images will be auto-generated.',
'type' => 'grid',
'width' => '1-2',
'fields' => ['image_width', 'image_height']
], 'image_card_padding', 'image_border', 'image_svg_inline', 'image_svg_animate', 'image_svg_color']
], [
'label' => 'Link',
'type' => 'group',
'divider' => true,
'fields' => ['link_type', 'link_target', 'link_text', 'link_style', 'link_size', 'link_margin']
], [
'label' => 'General',
'type' => 'group',
'fields' => ['position', 'position_left', 'position_right', 'position_top', 'position_bottom', 'position_z_index', 'margin', 'margin_remove_top', 'margin_remove_bottom', 'maxwidth', 'maxwidth_breakpoint', 'block_align', 'block_align_breakpoint', 'block_align_fallback', 'text_align', 'text_align_breakpoint', 'text_align_fallback', 'animation', '_parallax_button', 'visibility', 'container_padding_remove']
]]
], $this->get('builder.advanced')]
]
]
];