Is the overflow-x property causing the p tag content to spill out of the card?

Here is the HTML and CSS code to create a scrollable list of elements on a webpage. Currently, there is an issue where the paragraph data tag gets cut off when applying the overflow-x property. I have a div element containing image and paragraph tags with overflow properties set for the container.

<div class="container-fluid scrollmenu">
    <div class="row text-centre">
        <div class="scroll-data">

            <div class="col-xs-4 col-sm-6 col-md-4">
                <img class="d-block w-100 card-img-top" src="./Images/banner-1.jpg" alt="First slide">
                <p>Lorem Ipsum is simply dummy text of the printing and typesetting industry.
                       Lorem Ipsum has been the industry's standard dummy text ever since the 1500s</p>
            </div>

            ... (additional code for other items) ...

        </div>
    </div>
</div>

Css

.container-fluid .row .scroll-data { 
    overflow-x:auto; 
    white-space: nowrap; 
    display: flex;
} 

.container-fluid .row .scroll-data .col-xs-4 p {
    word-wrap: break-word;
    color: blueviolet;
}

Answer №1

What is the reason for including white-space: nowrap in the container? It appears to be preventing your text from wrapping properly. I recommend removing it to resolve the issue.

.container-fluid .row .scroll-data { 
    overflow-x:auto;  
    display: flex;
} 

Similar questions

If you have not found the answer to your question or you are interested in this topic, then look at other similar questions below or use the search

Is it possible to utilize multiple .html files in a single view while incorporating Materialize?

Within my AngularJS application that utilizes Materialize, I have a module called "reports" containing a view called "reports.html" intended to house all of my reports. However, I desire to separate the code for each report into individual .html files, suc ...

The issue of JQuery Datatables columns overlapping arises during the application of column filtering

I have integrated a Jquery DataTable inside a Bootstrap division. The Bootstrap row is split between the DataTable and a Chartjs chart. Initially, everything displays correctly without any overlapping. However, when I implemented code to enable column fil ...

Alignment in the vertical direction of two lines

I've been struggling to align some HTML elements visually the way I want. There are two lines of text followed by a link. I'm trying to get the link to be vertically centered between the two lines, rather than just after the second line. Using a ...

Incorporating Image Caching Optimizations in CSS

My current dilemma I currently implement Cache Busting for my CSS files like this: echo "&lt;link href='stylesheet.css?" . filemtime('stylesheet.css') . "' />" My objective Now I want to achieve a similar approach for th ...

What is the best way to incorporate a search bar into a dropdown menu?

Would someone be able to assist me in adding a search bar as the primary value of the dropdown menu? I am using ASP.NET MVC and this is my current code snippet. <div class="col-md-8"> <div class="dropdown"> <div class="chzn-d ...

Bootstrap 4: Popper not found - ReferenceError in the script

After setting up Bootstrap 4 using Node and Gulp, I encountered an error when running the application: Uncaught ReferenceError: Popper is not defined So far, I've only utilized the Bootstrap grid system and have not delved into the Bootstrap JS fu ...

The styling of the React component is not being applied as expected by the .Css file

My title component seems to be having trouble applying the CSS styles as expected. I'd like it to have a green background, but for some reason, it's displaying as white. Below is the Component Js file: import React from "react"; funct ...

Is there a way to display .form-check-inline buttons on a different line than their corresponding label?

I'm trying to create a form with radio buttons and using Bootstrap 4 to align them horizontally with the .form-check-inline class. However, this causes the input labels to be on the same line as the buttons: <html> <head> <link ...

Wordpress dynamic content enhanced with Bootstrap carousel

My current issue involves a Bootstrap carousel that I've implemented in WordPress. While the carousel itself is functioning properly, I'm having trouble getting it to link to specific articles when the images are clicked on. Can anyone offer advi ...

jquery activating the toggle function to switch between child elements

I'm facing a challenge where I can't use .children() in this scenario, as it won't work since the elements aren't technically children. Here's the snippet of HTML that I'm working with: <p class="l1">A</p> ...

What steps should I follow to make a dynamic carousel card with Bootstrap that adjusts to different screen sizes

My goal was to design a Bootstrap card with an embedded 'slideshow'. The idea was to use the second page to provide more information about the content on the first page. While editing this on the web, I managed to create a satisfactory product () ...

Leveraging the ng-hide property of one controller to adjust the ng-style attribute of another controller through a centralized global controller

Seeking assistance with accessing the boolean value of ng-hide from one controller in order to alter CSS properties of another controller utilizing a global controller. Here is the jsfiddle link: https://jsfiddle.net/dqmtLxnt/ HTML <div ng-controller= ...

Adjust the height value of each element to match the maximum height within a single line using only CSS

There are 3 divs styled with display:inline-block. I aim to adjust their height values so they match the highest one. The desired effect is demonstrated visually below. Is it doable using only CSS? ----- ----- ----- ----- ----- ---- ...

The font family specified in the Materia UI theme is experiencing compatibility issues on browsers that are not Chrome

Having difficulty overriding some elements with a specific font, as it seems to work perfectly on Chrome but not on other browsers like Safari and FireFox. Could there be something overlooked? Below is the code snippet: const customTheme = createMuiTheme( ...

Tips for displaying a Bootstrap 4 table on smaller screens

I have a Bootstrap 4 table filled with JSON data. The table renders perfectly on the UI, but users on smaller devices must scroll to view all the data. Despite there not being much data in the HTML table, users still need to scroll on small devices. I wa ...

A div positioned to the left is placed beneath another div

I am faced with a design challenge involving two divs. The first div is floated left, while the second div is floated right. In order to achieve a responsive layout, I need the first div to go under the second div when the viewport changes. Both divs conta ...

Issue with Vue2: DIV does not adjust height when using v-for loop

I have a div set up like: <div class="pt-4"> <h5>Genres:</h5> <div class="inline-block float-left" v-for="(genre, index) in moreData.genres" :key="index"> <span v-if="index < ...

Increase the character count when two spans contain data

I am currently working with the code provided below. The user interface allows users to choose either a single date or a range of dates. These dates are displayed within span tags, with a "-" symbol intended to be shown if there is a valid toDate. However, ...

"GitHub Pages encounter an issue locating the Bootstrap Sass during the build process

I'm currently working on a GitHub pages site (specifically, a project page) that utilizes Jekyll and I'm eager to incorporate Bootstrap into my project. To achieve this, I went ahead and downloaded the uncompiled twbs files and inserted the boots ...

"Enhance the functionality of multiple elements with this innovative Jquery

Exploring the realm of Jquery plugins, I am faced with the challenge of making my plugin compatible with multiple elements. After scouring tutorials and various online forums, I've come to realize that plugin development is heavily dependent on the sp ...