In banner component- If there is no content the div should not be visible on the frontend.

Created on 20 November 2023, about 1 year ago
Updated 24 June 2024, 5 months ago

Problem/Motivation

In the banner component- If there is no content the div should not be visible on the front end. The icon-box has no content inside it. It is still visible some styling is visible on the frontend. See attached screenshot.

Steps to reproduce

Install the theme and enable it.
Go to to the theme settings and open the banner config.
Inside the banner config there is a card box leave these fields blank and save the config.
See on the homepage banner. You will see the issue.

Proposed resolution

Remaining tasks

User interface changes

API changes

Data model changes

🐛 Bug report
Status

RTBC

Version

9.0

Component

Code

Created by

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

  • Issue created by @shweta__sharma
  • First commit to issue fork.
  • Merge request !22Banner block display condition enhancements → (Open) created by realsp
  • Status changed to Needs review 11 months ago
  • 🇮🇳India realsp

    I've added conditions for the case scenario when there's no-content inside icon-box & markup enhancements, when there's no-description in the banner, Please review the MR, Thank you.

  • Status changed to RTBC 11 months ago
  • 🇮🇳India Tirupati_Singh

    Hi @realsp, I've test the changes made on MR#22 and confirm that the issue has been resolved. Attaching screenshot for reference.

  • Status changed to Needs review 11 months ago
  • 🇮🇳India Tirupati_Singh

    Resolved the banner component issue using another approach, please review the changes.

  • Status changed to RTBC 6 months ago
  • Hi,
    I've encountered the aforementioned issue, and after applying both the patches the issue is getting resolved.
    Reviewed both the MR, both the MRs are looking good to me, but MR!23 provides a configuration option from the theme settings from which it lets the user to choose the number of slides, which not only solves the card rendering issue on the homepage, but also dynamically renders card components on the theme settings form based on the chosen value, for which it seems more of a robust solution to me!
    Attaching before and after screenshots for reference!

  • 🇮🇳India Tirupati_Singh

    @sourojeetpaul, thanks for the feedback. I've made changes for conditional rendering of banner title, banner description and banner slider. Please review the changes.

Production build 0.71.5 2024