Stars not functioning in Firefox for CSS Angular2 ng2-rating component

Recently, I've been utilizing the ng2-rating module found at https://www.npmjs.com/package/ng2-rating. However, an intriguing issue has arisen specifically in Firefox - a mysterious gap between the filled stars and empty stars. Strangely enough, this gap only appears once the browser window is moved after the page has loaded.

Below are snippets of the HTML and CSS code that relate to this problem:

<span _ngcontent-rmx-4="" class="stars_rating rating_list_review">     <rating _ngcontent-rmx-4="" _nghost-rmx-6="" ng-reflect-readonly="true" ng-reflect-model="4" class="ng-untouched ng-pristine ng-valid">
        <span _ngcontent-rmx-6="" aria-valuemin="0" class="rating readonly" role="slider" tabindex="0" aria-valuemax="5" aria-valuenow="4">
            <span _ngcontent-rmx-6="">
                <i _ngcontent-rmx-6="" data-icon="★" ng-reflect-class-name="star-icon half100" class="star-icon half100" ng-reflect-title="1" title="1">☆</i>
            </span><span _ngcontent-rmx-6="">
                <i _ngcontent-rmx-6="" data-icon="★" ng-reflect-class-name="star-icon half100" class="star-icon half100" ng-reflect-title="2" title="2">☆</i>
            </span><span _ngcontent-rmx-6="">
                <i _ngcontent-rmx-6="" data-icon="★" ng-reflect-class-name="star-icon half100" class="star-icon half100" ng-reflect-title="3" title="3">☆</i>
            </span><span _ngcontent-rmx-6="">
                <i _ngcontent-rmx-6="" data-icon="★" ng-reflect-class-name="star-icon half100" class="star-icon half100" ng-reflect-title="4" title="4">☆</i>
            </span><span _ngcontent-rmx-6="">
                <i _ngcontent-rmx-6="" data-icon="★" ng-reflect-class-name="star-icon half0" class="star-icon half0" ng-reflect-title="5" title="5">☆</i>
            </span>
        </span>
    </rating>
</span>
.stars_rating {
  display: block;
  text-align: center;
  line-height: 2em !important;
}

.rating_list_review {
  font-size: 14px;
}

@-moz-document url-prefix() {
    .star-icon{
        line-height: 28px !important;
    }
}

.star-icon[_ngcontent-rmx-6] {
    color: #ddd;
    font-size: 2em;
    position: relative;
}

If anyone has encountered a similar issue or has suggestions on how to resolve it, please share your insights. This puzzling gap dilemma is truly testing my patience!

Answer №1

To enhance the text readability

include: line-height: 1.2;

within the star-icon[_ngcontent-rmx-6]{} section.

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

The error message "TypeError: finalizer.unsubscribe is not a method in Angular Ionic" suggests

I am experiencing difficulties with posting to the API while using a base class. I'm unsure how to resolve the issue mentioned below. Any assistance would be greatly appreciated. core.mjs:7635 ERROR Error: Uncaught (in promise): UnsubscriptionErr ...

Complete the missing elements of a CSS grid layout

I'm currently working on creating a grid layout that aligns with this wireframe design: https://i.sstatic.net/AdsMX.png Here is the markup I have implemented so far: <div class="grid"> <div class="spanWidth"> <img src="https:// ...

Why does the OpenApi Generated ApiModule in Angular fail to register when declared in the node_modules directory but functions properly when placed outside that folder?

Encountering a problem with consuming OpenApi Generated files (services, interfaces) via NPM package. Strangely, it works outside the node_modules folder but ApiModule is undefined when placed within. Refer to the Github link below for documentation on usa ...

Ways to stop a JS plugin affecting HTML anchors and preventing them from automatically scrolling to the top

My friend is working on a website and he's using a plugin called Flip Lightbox. The basic functionality of the plugin is that when you click on an image, it flips over and pops out as a lightbox. Everything works fine, however, if you scroll down the ...

Styling Excel Columns in Angular

Is there a way to make the column titles bold in an Excel worksheet using the json_to_sheet function? Specifically, how can I bold the ID or format the first cell? var ws = XLSX.utils.json_to_sheet([{ID:"ID"}], {header: ["ID"], skipHeader: true}); let exce ...

Pass a method parameter in the subscribe function in Angular

I am looking to utilize the subscribe method within a function, in which I pass my variable (cities) as a parameter. export class MyComponent implements OnInit { cities:any; constructor(private myApiService: MyApiService) { myMethod(this.cities); ...

CSS-Inlined equivalent for an empty td cell

Is there an alternative inline CSS solution for the following CSS selector: table td:empty { visibility: hidden; } What should be used instead of this? <table style="???"> <tr> <td></td> <!-- content will be added late ...

Is it possible for the Jquery Accordion to retract on click?

Hello everyone, I've created an accordion drop-down feature that reveals content when the header of the DIV is clicked. Everything works fine, but I want the drop-down to collapse if the user clicks on the same header. I am new to JQUERY and have trie ...

Guide on Modifying the CSS File of an Installed Plugin on WordPress

I am looking to customize the design of a WordPress plugin by editing its CSS file. When trying to locate the CSS file of the installed plugin through Plugins --> Installed Plugin --> Editor, I could only find .php files instead of the desired CSS f ...

Adjusting transparency on various DIV elements

Currently, I am working on implementing the 'OnClick' functionality in jQuery. The goal is to have only the parent div and its child divs displayed when we click on the parent div property, while fading out all other divs. Below you can find the ...

Updating an object property within an array in Angular Typescript does not reflect changes in the view

I am currently delving into Typescript and Angular, and I have encountered an issue where my view does not update when I try to modify a value in an array that is assigned to an object I defined. I have a feeling that it might be related to the context b ...

Facing unexpected behavior with rxjs merge in angular5

import { Observable } from 'rxjs/Observable'; import 'rxjs/add/observable/merge'; this.data = this.itemsCollection.valueChanges() this.foo = this.afs.collection<Item>('products') .doc('G2loKLqNQJUQIsDmzSNahlopOyk ...

Angular aggregates information from numerous HTTP inquiries

I am looking to retrieve data for multiple ProductIds from a remote source using httpClient in an angular service. My goal is to merge the data within the service and then send it back. When working with just one productId, everything functions correctly: ...

Is there a way for me to tweak the images on my website in a particular way?

Here’s the situation with my website: I have two images displayed: a border (image on the right) and a photograph (on the left). I am trying to place the photographic image inside the bordered image. Just to clarify, I can't create a new border as ...

Errors related to Angular StaticInjector for the classes Location, LocationStrategy and PlatformLocation

I have developed a versatile npm module that is compatible with any Angular 5 application. The shared module includes a universal service that utilizes Location injection. Here is an outline of the global service: global.service.ts import {Location} from ...

Leveraging the (click) event within an HTML template to manage a [hidden] element located in a different template using Angular 2

Within my project, I have two TypeScript files, each containing HTML templates inside the @Component. In one of the templates, there are info cards that can be collapsed or expanded using [hidden]="collapsed". The following function is present in both file ...

The documentation for Angular guards is riddled with vague and obfuscating statements

I've been delving deep into Angular lately, and I found the documentation to be quite enlightening. currently, I'm focused on learning about guards. In my research, I came across this intriguing statement: The router evaluates CanDeactiva ...

Changing the color of text in an HTML input field using CSS and JavaScript depending on the input value

Looking for a solution! // Getting user input values var input1 = parseInt(document.getElementById("input1").value); var input2 = parseInt(document.getElementById("input2").value); var input3 = parseFloat(document.getElementById(" ...

Javascript is responsible for causing a div to become stuck in a loop of alternating between

My current challenge involves a JavaScript function that manipulates boxes by toggling classnames. The strange issue I'm facing is that the correct classes are being set at the correct times, but the div keeps alternating between the original class an ...

Strange rendering in CSS JQuery Datatable

I am encountering an issue with a DataTable from datatables.net. Each row can be selected by clicking on a checkbox, which triggers a click event. In response to the event, I add or remove a CSS class to change the appearance of the selected rows. $(".cbD ...