Having difficulty handling text overflow in Angular4 and HTML

I'm facing an issue with displaying a very large text in a table. Despite trying various attributes such as -

{ text-overflow: clip; }

{ text-overflow: ellipsis; }

{ text-overflow: ellipsis-word; }

{ text-overflow: "---"; }

{ text-overflow: ellipsis ellipsis; text-align: center; }

and also using -

overflow-wrap: break-word;

However, when I use the slice function in my component.html, it prevents the tooltip from appearing which is crucial for me.

I need some suggestions on adjusting the CSS to address this problem.

Here is the image showing the overflow

component.css

 #addbtn{
 float:right;
  }
 thead>tr>th:hover {
 cursor: pointer;
 background-color: #384c57;
 color: rgb(240, 202, 132);
 box-shadow: 0 4px 8px rgba(0, 0, 0, 0.12), 0 4px 8px rgba(0, 0, 0, 
 0.24);
 }
th{
width:1px;white-space:nowrap;
}

table{
font-family: Arial, Helvetica, sans-serif;
 }

thead{
background-color: #33444d;
color: white;
 }


.card{
border: none !important;
 }


#faIcon{
background: #2f4855;
color: white;
border: none;
 }

input:hover {
background-color: rgb(247, 185, 114)  
 }

 input:focus{
 border : 2px solid rgb(247, 185, 114) !important;
 }

 .panel {
 border: none;
 margin-bottom: 0
  }

.panel-transparent {
 background: none;
 }

td{
height:10px;
}

.zoom {
 padding: 50px;

 transition: transform .2s; /* Animation */

 margin: 0 auto;
 }

 .zoom:hover {
transform: scale(3.0); /* (150% zoom - Note: if the zoom is too large, 
 it will go outside of the viewport) */
}


.table{
 color:rgb(255, 255, 255); background-color:rgba(17, 26, 24, 0.452);
 }

.panel-transparent .panel-heading{
background: rgba(44, 51, 59, 0.575)!important;
text-align: center;
color: #fff;

}

.my-pagination /deep/ .ngx-pagination .current {
background: #33444d;

 }

 #close{
 color:#708e9e;
 }

#close:hover{
color: white;
size: 25px;
}

#payloadData{
// border-image-slice: 10%;
 width:15px;
// word-break: break-all;

// box-decoration-break: slice;
white-space: nowrap; 
overflow-wrap: break-word;
overflow: hidden;
text-overflow: ellipsis ellipsis; text-align: center;
direction:ltr;
word-break: break-all;
//  text-overflow: ellipsis;
// text-overflow: ellipsis-word;
 }

component.html

   <td  title="{{dat.PAYLOAD}}" id="payloadData"> 
  {{dat.PAYLOAD}}</td>

Answer №1

Try implementing the word-break: break-word; property rather than using overflow-wrap: break-word;. Additionally, consider setting a max-height for the outer div and utilizing overflow-y:auto. These adjustments could potentially prove beneficial.

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

What steps do I need to take to activate this JQuery plugin successfully?

I stumbled upon this amazing silky smooth marquee jQuery plugin online @: Smooth marquee After downloading the latest JQuery and the JQuery marquee plugin as directed on the site above, I am still unable to make it work like they showcased in their demo: ...

Is it possible to eliminate the black bars from YouTube HQdefault image using only CSS?

(After searching extensively, I couldn't find the exact same question and answer) I have a dilemma with displaying YouTube's hqdefault thumbnails on my page. It seems that they are 480 by 360 pixels, resulting in black bars at the top and bottom ...

Tips for implementing SVG in background images on Internet Explorer

Having a similar issue to the one discussed in this thread. My background images are functioning properly on all browsers except for versions lower than IE10. After reading through that post, I created a background image in SVG format specifically for IE10 ...

Tips for calculating the total of keyup elements in an Angular application

There are "N" inputs in a formgroup that need to be summed: <input (keyup)="sum($event)" type="text" name="estoque_variacao{{i}}" class="form-control" id="estoque_variacao{{i}}" formControlName="estoque_variacao"> This is the Typescript code: sum( ...

Styling Challenges with CSS/AngularJS Accordion in Footer

I want to create a page layout as shown below: +---------------------------+ | Auto-fill / v scrollable ^| | || | || | v| +---------------------------+ | Fixed [][][] ...

How to Share Angular Modules Between Two Projects with Ivy Compilation Necessity

Query: I am faced with the challenge of sharing common modules between two Angular projects, one of which requires full Ivy compilation to function properly. To manage these shared resources, we have set up a private GitHub NPM repository. However, becaus ...

Changing the z-index using createjs

Is there a way to ensure that the dragged item always stays on top when moved? How can I prevent it from getting dragged underneath another object? Can I specify which "sequenceNumbers" should be moved to the top of the sorting order? //++++++++ ...

An error occurs when trying to modify the classList, resulting in an Uncaught TypeError for setting an indexed property

I am attempting to modify the classes of multiple sibling elements when a click event occurs. Some of these elements may have multiple classes, but I always want to change the first class. Below is the code that I created: let classList = event.currentTa ...

Maintaining the aspect ratio of images in Bootstrap Carousel: A complete guide

Using the default carousel from Bootstrap template has been working well for me. However, I've encountered an issue where resizing the browser window distorts the image aspect ratio by squishing it horizontally. I've tried various solutions to m ...

Is it possible to securely share login details on the internet?

I'm currently brainstorming different ways to securely display FTP, database, and hosting information for website projects on my project management site. One potential solution I'm considering is encrypting the passwords and developing an applica ...

What could be causing the issue with my css `content:` not functioning across different browsers, and how can I enhance cross-browser compatibility in all cases

Working on my first HTML/CSS project, I encountered a browser compatibility challenge. The code functions well in Firefox, IE, and Edge but fails in Chrome. Specifically, I am trying to make a button display alternating up and down arrows when clicked. Whi ...

Adjust the anchor tag content when a div is clicked

I have a list where each item is assigned a unique ID. I have written the HTML structure for a single item as follows: The structure looks like this: <div id='33496'> <div class='event_content'>..... <div>. ...

Approach to decoupling design elements from DOM interactions

Seeking recommendations or guidelines for effectively segregating classes utilized for browser styling and DOM manipulation. Specifically, we are developing a single-page app using backbone.js and heavily relying on jQuery for dynamically updating page el ...

Expansive Offspring Division stretching to the Entire Vertical Length of its Guardian Division

I'm attempting to achieve full coverage of the parent div section by my child div section. Take a look at the Example URL (specifically where the Canadian Flag Stand Up Paddle Boarders are located) towards the bottom: Essentially, when I set the widt ...

Is there a way to access a component based on its route in Angular 7?

I am currently utilizing the NavigationEnd event to identify the current route after it has been changed in the following way: this.router.events.pipe( filter(event => event instanceof NavigationEnd) ).subscribe((event) => { const na ...

Getting variables from different functions in Python can be achieved by using the return

I am trying to implement a feature where I can fetch a search term from the function getRandomVideo() and then use it in a jQuery statement. For example, if I get "Beethoven" as the search term from the variable searches, I want to use it to retrieve JS ...

triggering a button click event in HTML

Below is the creation of a div: <div class="area1"> </div> By using AJAX, I was able to alter the HTML for the aforementioned div with this call: $('#abutton').click(function(e) { e.preventDefault(); ...

Customize your website with CSS and Bootstrap: create a transparent navbar-wrapper

Is there a way to make the menu bar background transparent without affecting the transparency of the text on the menu bar? This template is based on Twitter Bootstrap carousel. In this specific line, <div class="navbar navbar-inverse navbar-static-to ...

The console errors in the test are being triggered by the Angular setTimeout() call within the component, despite the test still passing successfully

I am currently experimenting with a click action in Angular 7 using an anchor tag Below is the markup for the anchor tag in my component <div id="region-start" class="timeline-region"> <div class="row"> <div class="col-12 col-md- ...

Could we customize the appearance of the saved input field data dropdown?

I'm currently working on styling a form that includes an input field. The challenge I'm facing is that the input field needs to be completely transparent. Everything works fine with the input field until I start typing, which triggers the browser ...