Skip to content
Guides
Navigation
Feedback
Overlays
Layout
Data Display
Forms
.md

FAQ

faq-02

Left-aligned FAQ: title, a full-width accordion of questions and a contact prompt underneath.

Open full screen

Installation

php artisan ui:add-block faq-02

A single command installs the block's Blade file and every component it depends on. Render it in your own layout as <x-ui.blocks.faq-02 />.

Components it includes

Usage

Left-aligned FAQ: title block, a full-width accordion of questions and a "Still have questions?" contact prompt. Every piece of content is a prop. Each item is ['question' => ..., 'answer' => ...]. Set :schema="true" to print FAQPage JSON-LD for search engines.

<x-ui.blocks.faq-02
    heading="Frequently asked questions"
    description="Everything you need to know about billing and accounts."
    :items="[
        ['question' => 'Can I cancel at any time?', 'answer' => 'Yes. Cancel from your billing page and you keep access until the period ends.'],
        ['question' => 'Do you offer refunds?', 'answer' => 'We refund any payment made in the last 14 days.'],
    ]"
    cta-heading="Still have questions?"
    cta-text="Our team answers within one working day."
    cta-label="Contact us"
    cta-href="/contact"
    :schema="true"
/>

Props

Every prop with its default. Pass any of them as attributes, using : to bind a PHP value.

@props([
    'heading' => 'FAQs',
    'description' => 'Lorem ipsum dolor sit amet, consectetur adipiscing elit. Suspendisse varius enim in eros elementum tristique.',
    'items' => array_fill(0, 5, [
        'question' => 'Question text goes here',
        'answer' => 'Lorem ipsum dolor sit amet, consectetur adipiscing elit. Suspendisse varius enim in eros elementum tristique. Duis cursus, mi quis viverra ornare, eros dolor interdum nulla, ut commodo diam libero vitae erat. Aenean faucibus nibh et justo cursus id rutrum lorem imperdiet. Nunc ut sem vitae risus tristique posuere.',
    ]),
    'ctaHeading' => 'Still have questions?',
    'ctaText' => 'Lorem ipsum dolor sit amet, consectetur adipiscing elit.',
    'ctaLabel' => 'Contact',
    'ctaHref' => '#',
    'schema' => false,
])