start_controls_section( 'faq-section', [ 'label' => __( 'Faq', 'ai-elementor' ), ] ); $this->add_control( 'image', [ 'label' => __( 'Image', 'plugin-domain' ), 'type' => Controls_Manager::MEDIA, 'default' => [ 'url' => \Elementor\Utils::get_placeholder_image_src(), ], ] ); $repeater = new \Elementor\Repeater(); $repeater->add_control( 'faq_title', [ 'label' => __( 'Faq Title', 'ai-elementor' ), 'type' => Controls_Manager::TEXT, 'default' => __( 'Insert faq title here' , 'ai-elementor' ), 'label_block' => true, ] ); $repeater->add_control( 'faq_content', [ 'label' => __( 'Faq Content', 'ai-elementor' ), 'type' => Controls_Manager::TEXTAREA, 'default' => __( 'Insert faq content here' , 'ai-elementor' ), ] ); $this->add_control( 'faq_items', [ 'label' => __( 'Faq Items', 'ai-elementor' ), 'type' => Controls_Manager::REPEATER, 'fields' => $repeater->get_controls(), 'title_field' => '{{{ faq_title }}}', ] ); $this->end_controls_section(); $this->start_controls_section( 'about_us_style', [ 'label' => __( 'Style', 'ai-elementor' ), 'tab' => Controls_Manager::TAB_STYLE, ] ); $this->add_control( 'bg_color', [ 'label' => __( 'Section Color', 'ai-elementor' ), 'type' => Controls_Manager::COLOR, 'selectors' => [ '{{WRAPPER}} .check-mark-icon-font' => 'color: {{VALUE}}', '{{WRAPPER}} .icon-font-box i' => 'color: {{VALUE}}', '{{WRAPPER}} .icon-font-box' => 'border: 2px solid {{VALUE}}', ], ] ); $this->end_controls_section(); } /** * Render the widget output on the frontend. * * Written in PHP and used to generate the final HTML. * * @since 1.0.0 * * @access protected */ protected function render() { $settings = $this->get_settings_for_display(); ?>