get_settings(); $nonce = wp_create_nonce( 'aiforya_fg_nonce' ); $position = (string) $settings['position']; $layout = (string) $settings['layout']; $default_title = (string) $settings['default_title']; $color_primary = (string) $settings['color_primary']; $color_bg = (string) $settings['color_bg']; $color_text = (string) $settings['color_text']; $color_question = (string) $settings['color_question']; $positions = [ 'manual' => __( 'Manual — only where the shortcode or the block is placed', 'aiforya-faq-generator' ), 'after' => __( 'Automatic — after the post content', 'aiforya-faq-generator' ), 'before' => __( 'Automatic — before the post content', 'aiforya-faq-generator' ), ]; $layouts = [ 'accordion' => __( 'Accordion — clickable question, expandable answer (recommended)', 'aiforya-faq-generator' ), 'cards' => __( 'Cards — grid of Q&A cards', 'aiforya-faq-generator' ), 'list' => __( 'List — all answers shown', 'aiforya-faq-generator' ), 'numbered' => __( 'Numbered list', 'aiforya-faq-generator' ), 'minimal' => __( 'Minimal — no borders or background', 'aiforya-faq-generator' ), ]; $colors = [ 'color_primary' => [ __( 'Accent (borders)', 'aiforya-faq-generator' ), $color_primary ], 'color_bg' => [ __( 'Block background', 'aiforya-faq-generator' ), $color_bg ], 'color_question' => [ __( 'Question text', 'aiforya-faq-generator' ), $color_question ], 'color_text' => [ __( 'Answer text', 'aiforya-faq-generator' ), $color_text ], ]; // Helper D2 : pastille d'aide « ? » charte (AiforyaTooltip). $text déjà traduit. $tip = static function ( $text ) { printf( '', esc_attr( $text ) ); }; ?>
[aiforya_faq]
[aiforya_faq post_id="42"]
[aiforya_faq title="Your questions"]