How can you enable scrolling on overflow in a Bootstrap column?

<body class='container-fluid mx-auto' style='width: 95%'>
<div class='row'>

<div
    id='video_container'
    class='
        embed-responsive
        embed-responsive-16by9
        card card-body rounded-0 border-0
        col-9'>
    <div id='player'></div>
</div>

<div
    id='chat_container'
    class='card card-body rounded-0 col-3'
    style='overflow-y: scroll'>
</div>

</div>
</body>

To maintain the responsiveness of video_container and ensure that both video_container and chat_container have the same height without the chat_container expanding further below when filled with chats, you can set overflow-y: scroll in the CSS for the chat_container. It's important to note that the style attribute may sometimes disappear when added directly to an element.

In your local head file (downloaded copy), you should have the following:

<link rel='stylesheet' href='bootstrap.min.css'>
<script src='jquery-3.3.1.slim.min.js'></script>
<script src='bootstrap.min.js'></script>
<script src='popper.min.js'></script>

Answer №1

To accomplish this task, you need to establish your very own video-chat-row class. Please be aware that when utilizing the embed-responsive-16by9 class, the regular behavior of the row and col-x classes may not apply as expected. You will have to create your own custom overrides for these.

.video-chat-row {
  display: flex;
  width: 100%;
  position: relative;
}

#video_container {
  flex: 0 0 75%;
  background-color: black;
}

#chat_container {
  position: absolute;
  width: 25%;
  left: 75%;
  top: 0;
  bottom: 0;
  right: 0;
  overflow-y: scroll;
}
<link href="https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/4.0.0/css/bootstrap.min.css" rel="stylesheet"/>
<body class='container-fluid mx-auto' style='width: 95%'>
<div class='video-chat-row'>

<div
    id='video_container'
    class='
        embed-responsive
        embed-responsive-16by9
        card card-body rounded-0 border-0' >
    <div id='player'></div>
</div>

<div
    id='chat_container'
    class='card card-body rounded-0'>
    <p>Content goes here...</p>
    <p>More content goes here...</p>
    <p>Even more content goes here...</p>
    
</div>

</div>
</body>

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

After being reloaded multiple times, the time and date mysteriously vanish

Issue with Javascript/jQuery/jQuery Mobile Code After reloading or refreshing the page multiple times, the values for currentDate and currentTime seem to disappear sporadically. Strangely, they start working fine again after a few more reloads. Can anyone ...

What is the correct way to specify the type in my functional component?

I was trying to define the type in my component in a different way, I know it can be done using classes but is there a way to achieve this with functional components without exporting the interface? Despite my extensive research, I couldn't find any r ...

Retrieving a particular key and its corresponding value within a jQuery object

In my current project, I have a PHP associative array where I am fetching keys and values and passing them to a jQuery object: $names = array("Peter"=>"35", "Ben"=>"37", "Joe"=>"43"); $js = json_encode($names); echo 'var names= ' . $js ...

Identifying the relationship between child and parent components in Vue.js

I am new to Vue.js and I am practicing some simple exercises on communication between Vue components. However, I am struggling with understanding who is a child component and who is a parent component. For example, consider the following code snippet: HTM ...

Exploring ways to capture all console outputs or retrieve the current console content in frontend development

Currently working with Angular and looking to integrate a bug reporting feature into my application. I want to capture the content of the browser's console for debugging purposes. However, I'm unsure of how to access it. Not all errors are logge ...

Filtering data from an Ajax request in Angular using a filter function with JSON

Hi everyone, I recently started learning AngularJS and created a basic item list with search functionality and pagination. Everything was working smoothly, so I decided to move my list outside the controller and store it as a JSON file. Here's what ...

Yii, the datepicker does not have the functionality to stack options

Initially, I had a datepicker set up to prevent users from selecting days before the current day. However, I decided to incorporate a new function called DisableMondays which disables all Mondays. But after adding this function, I noticed that I was able ...

The functionality of onClick and console.log seems to be malfunctioning on Nextjs

I'm currently learning NEXT but I've encountered some issues with certain functions "use client" import { useState } from 'react' export default function idk() { const [counter,setCounter]=useState(0) const add=()=> ...

Tips for adding an asterisk to the label of a Material-UI switch component

I am trying to include an asterisk symbol in the label by passing a required prop with a property, but it doesn't seem to be functioning correctly. <FormControlLabel control={ <Switch onChange={event => ...

I am currently facing an issue with retrieving the class value that is being generated by PHP code

I am currently facing an issue with jQuery and PHP. Whenever I attempt to target the click event on the class ".id_annonce" in the dynamically generated PHP code, it doesn't retrieve the exact value of what I clicked. Instead, it always gives me a fi ...

Undefined jQuery was encountered on the object when using the appropriate selector

Having a jQuery issue with the following HTML code snippet: <div class="side-finder"> <div class="brand"><img src="/img/test.net-logo.png" /></div> <div class="finder-content"> <ul class="nav nav-pills nav-stacked" id= ...

What is the most effective way to transfer information from one page to another in a PhoneGap application?

I attempted to transfer data from one HTML page to another using two different methods: function reply_click(clicked_id) { window.location = "newsList.html?Title="+clicked_id; } And I also tried: function reply_click(clicked_id) { window.l ...

Modifying the style of a specific row when the form is submitted

My webpage contains nested records, with each nested record displaying a total number of clicks in a div labeled "count". I am looking to increment the count by 1 for each specific record when the button with a class of view is clicked. Currently, clicking ...

The Router.use() function is looking for a middleware function, but instead received an undefined value at the

Currently, I am working on implementing authentication with node.js following a tutorial. However, I have encountered some issues that I am struggling to resolve. This is how I have configured the server: // Inserted code for configuring the server The ...

The Droppable feature in jQuery/jQueryUI molds itself to match the shape of the Dragged

In my current setup, I am working with a single column table where each cell is a droppable element that only accepts draggables of a specific class. While the borders of the table are visible, I am not a fan of the fixed size and colored cells within, a ...

Grails 3.1.9 does not support displaying JavaScript

Having trouble getting the datepicker to display using JavaScript <script> $( "#invoiceDate" ).datepicker({ inline: true, dateFormat: "yy-mm-dd", onSelect: function(datetext){ datetext = datetext+" 00:00:00.0" ...

When attempting to reload a single page application that utilizes AJAX, a 404 error is encountered

Recently, I've been working on coding my personal website and have successfully created a single page application using ajax. The content is dynamically loaded between the header and footer whenever a navigation bar link is clicked. To enable the back ...

Juggling Asynchronous GET Requests in JavaScript?

Despite my efforts to find a solution, I'm struggling to come up with the right words or approach... here's the situation: In my ASP.NET MVC application, users scan inventory or package barcodes. Each scan triggers an async request, and a popup ...

The AreaChart in Google is displaying incorrect dates on the axis

I have encountered an issue that I am struggling to resolve. I am in the process of creating a Google Area Chart using a JSON response from a server, specifically with date type columns. Below is the JSON data obtained from the server (copy/paste), organi ...

Why is my IEDriverServer typing so slow? Seeking JavaScript solutions

While working with Selenium and IEDriverServer, I have encountered an issue where the keys are being sent to the input at a very slow pace. After conducting some research, many websites recommend ensuring that the Browser and IEDriverServer are of the sam ...