Skip to main content

Questions tagged [css]

Cascading Style Sheets (CSS) is a language for specifying the layout and presentation in general of markup such as HTML and XML.

Filter by
Sorted by
Tagged with
5 votes
2 answers
1k views

I have the plan for an UI component hierarchy. Each UI component contains zero or more children UI components, and each UI component may set an optional theme. A theme is responsible for skinning a ...
Hydroper's user avatar
  • 197
-1 votes
2 answers
213 views

<div> tags are display: block per default. <span> tags are display: inline per default. Could there be a tag that is display: flex per default? I don't mean a class, like bootstrap has. I ...
Lycodo's user avatar
  • 13
1 vote
1 answer
562 views

I really don't like media queries in CSS - they have limitations, and on top of that they make the code a lot more confusing. In addition, the restrictions are so strong that when using CSS ...
GeeWay's user avatar
  • 21
1 vote
2 answers
81 views

I'm writing a Python CSS-selector library that allows one to write these kinds of expressions in Python as a pet project. The goal of the library is to represent selectors in a flat, intuitive and ...
InSync's user avatar
  • 137
1 vote
2 answers
110 views

So nowadays, creating js & css that works the same across different browsers is less of an issue as to what it was a few years back. So let's say I have this Vue app that - Has CSS reset Include @...
Haim's user avatar
  • 119
-1 votes
1 answer
199 views

I am creating SCSS for the large project, I decided to use BEM methodology. I will have a lot of containers. I have question about BEM and about best practices. My current code: .footer { &...
user avatar
0 votes
1 answer
308 views

This question is mainly about readability and understanding of the code. Im am also in the process of creating a SCSS framework like Compass and Bourbon. I struggle to write SCSS because I like to see ...
Pagel's user avatar
  • 11
1 vote
1 answer
425 views

I maintain a CSS framework that is versioning with semantic versioning. What changes to a CSS framework are considered major, minor, and patches? Specifically, what is the "API" of a CSS ...
Kyle Pollard's user avatar
  • 127
1 vote
1 answer
388 views

What are the advantages and disadvantages of including JS/CSS inside the HTML instead of separated files? Specifically concerned about performance issues, for example, if the CSS and JS are small and ...
MauricioRobayo's user avatar
-3 votes
1 answer
107 views

I'm working on a CSS library that includes hundreds of selectors and rules for quick templating instead of writing regular CSS. This is used as a replacement of attr() CSS function until it works for ...
Tot's user avatar
  • 147
-3 votes
1 answer
119 views

I know that Inline CSS styling gets so much hate from many developers, and I understand that some of this hate is justified by the following facts: Inline styles increase page size as they don't get ...
Tarek's user avatar
  • 1
2 votes
0 answers
2k views

I have a site where users upload images & can all be viewed on a single page by other users. I want to lazy load images as the user scrolls instead of loading all initially. This is easy enough, ...
Avery Ferrante's user avatar
-3 votes
1 answer
5k views

I've tried everything related to filter and backdrop-filter, but nothing seems to work. I've searched online but not found a single article addressing this (which is odd). I simply want to set the ...
Nafur's user avatar
  • 21
0 votes
1 answer
1k views

Let's say you have a scenario where you want to build a simple web stack (html/css/js) prototype to share with someone. I am a little unclear on whether or not I want/need to use a small web-server to ...
z0d14c's user avatar
  • 111
-3 votes
1 answer
80 views

How would you architect a simple cascading stylesheet like inheritance object? For example, I have Apple that extends Fruit. class Fruit { constructor() { this.total = 10; } } ...
1.21 gigawatts's user avatar
6 votes
2 answers
989 views

CSS is a syntax for specifying the appearance of text and other web content, sizes and lengths are defined in pixels, however pixels have different sizes in different devices, this is the most notable ...
TZubiri's user avatar
  • 443
-3 votes
3 answers
169 views

I'm expirementing with creating a website as a IT Ticketing system. This website has a top nav and a side nav. I want the content area to change depending on the link clicked. I've managed to get the ...
Jacob Lamattina's user avatar
1 vote
0 answers
37 views

I have a common style (common.scss) and a text direction (RTL, LTR) option file (option-document-direction-rtl.scss, option-document-direction-ltr.scss). And by switching the reading of these files, ...
stealegi's user avatar
-1 votes
1 answer
1k views

In HTML/CSS, inline elements, such as <span>, do not support explicitly setting their width via the width CSS property. This is confusing to many developers, as questions like "Setting the ...
sleske's user avatar
  • 10.3k
0 votes
0 answers
938 views

I've been working on a web app that's divided up into different web pages (around 20). It's only used within my company and it looks at financial data. It's a few years old and is in dire need of an ...
Bodrov's user avatar
  • 109
-3 votes
3 answers
2k views

I'm a backend developer working on a webpage, building the CSS part. I like to write as less code as possible and reuse them throughout the site, a lot of pages. I want to be able to reuse some CSS ...
samceena's user avatar
  • 189
3 votes
2 answers
182 views

There are a number of CSS frameworks that have a one-to-one correspondence between many of the classes and a single style. For example, in basscss ".inline-block" is defined as "display: inline-block;...
James K's user avatar
  • 41
1 vote
2 answers
2k views

As far as I know, each webpage is created in a two stage process, initiated by a webserver request and ended in a webserver response: Parsing: markup (Say HTML) is executed as is, or created by ...
user avatar
2 votes
1 answer
300 views

It seems like HTML5 has about a zillion different layouts and methods for positioning divs, few of which seem to work exactly as described in most browsers. Imagine an implementation of, say, Tetris ...
Daniel McLaury's user avatar
0 votes
1 answer
154 views

Our team is attempting to "modernize" an old ASP.NET Web Forms application. One aspect we want to improve is its visual style as it looks very dated by today's standards. Additionally, its existing ...
Jake Shakesworth's user avatar
0 votes
1 answer
143 views

This may be an obvious question but I really don't understand this so if someone can help me that'd be great. Basically, I am in the middle of developing an e-commerce app for my database management ...
DylanG1991's user avatar
0 votes
1 answer
234 views

I've always used CSS and media queries when it comes to responsive design. I've been developing in ReactJS for a while, but I feel my approach to responsive design is sloppy. I find myself using a mix ...
sme's user avatar
  • 101
1 vote
1 answer
1k views

I have a website that follows the following structure: www.example.com/city1 www.example.com/city2 ... Programmatically we change the logo which is hard-coded in a specific config file for city 1, ...
Dennis's user avatar
  • 139
3 votes
2 answers
177 views

So there are a fair few blog posts about that introduce CSS modules. For example: the official documentation: https://github.com/css-modules/css-modules a post from CSS Tricks: https://css-tricks....
dwjohnston's user avatar
  • 2,769
2 votes
2 answers
12k views

Since there is things like BEM in naming conventions for HTML class attributes, does the name attribute have anything of that sort?
ARLCode's user avatar
  • 197
-2 votes
1 answer
191 views

Can you do everything that CSS Grid or Flex box does with properties such as display, float, margin, position, overflow, etc ? Edit: See my comment with @PeeyushKushwaha
Norman Potts's user avatar
1 vote
3 answers
130 views

For example, to create flow indicator like: Step 1 > Step 2 > Step 3 I can either: 1.Use html+css .concave{ border-left:1em solid transparent; border-top:1em solid orange; border-bottom:...
ocomfd's user avatar
  • 5,760
0 votes
2 answers
204 views

We've been using BEM for several Drupal CMS projects quite successfully. This means we've been following a frontend-first approach where frontend developers specify the HTML, which is then implemented ...
dude's user avatar
  • 61
4 votes
1 answer
629 views

Maybe I'm not the first to ask this, but I've searched up and down the stack and I am yet to get an answer to my question. I have learnt CSS, and I also have a basic idea of the C programming language....
Kailash Shankar's user avatar
-3 votes
1 answer
141 views

Is there a best practice for naming class selectors for identification alone? For example, for defining a single amount field with action button, we end up creating several div containers and div ...
Teddy's user avatar
  • 95
1 vote
2 answers
3k views

I am making a website for a competition my school is taking part in, however I am not on the team and am not receiving any compensation (save for better references :P). The only condition I have set ...
DividedByZero's user avatar
0 votes
1 answer
246 views

Is it good practice to express the state of an HTML element--such as whether an input's value is valid--using a CSS class? Would it be better practice to use data attributes, the properties of a ...
Allie Fitter's user avatar
-3 votes
1 answer
551 views

I was just trying IDs on the CSS tab and I noticed that a little warning sign appeared "Don't use IDs in selectors" Why does the CSS tap recommend me not to use IDs in selectors?. Is there something ...
Raj Patel's user avatar
1 vote
1 answer
142 views

I've been looking for a good way to style a react component just using css stylesheets. I would have used style-loader, because it's as easy as require('./style.css') and allows to save the final ...
guitarino's user avatar
  • 113
5 votes
0 answers
1k views

What are some best practices for writing memory-efficient (for the lowest peak memory usage) CSS? I realize this is a broad question, so I have broken it down into two main categories: What are 'do's ...
Jack G's user avatar
  • 242
3 votes
3 answers
974 views

Imagine a structure like this, a list with products. <div class="container"> <div class="teaser"> <img src="..."> <p>Product 1</p> </div> ...
Daniel W.'s user avatar
  • 555
15 votes
2 answers
17k views

As far as I know there are two types of CSS namespacing: Prefix one: .myapp-alert {...} and class one: .myapp .alert {...} Which one is preferable? Does one has benefits over the other one? Are ...
Runnick's user avatar
  • 215
17 votes
4 answers
7k views

If you look at the source code of a website such as Facebook, you'll see many classes as such: <div class="_cy6 _2s24"><div class="_4kny"><div class="uiToggle _8-a _1kj2 _4d1i _-57 _5-...
1234567's user avatar
  • 335
0 votes
1 answer
221 views

Firstly i hope im in the right place to ask this question. I am building a web page that allows the user to select one image from a set of a 100+. i want to display them 6 at a time and the user ...
Lonergan6275's user avatar
1 vote
1 answer
225 views

Context: We're having a ton of super heated debates around the office. I'm just a neutral observer, as this is my first month at my current employer. Previously I haven't ventured outside of the ...
Rohan Büchner's user avatar
1 vote
2 answers
172 views

I'm currently working on a site for a friend, converting a google sheet to a webpage (to reduce the time it takes to modify the spreadsheets and apply them to all users). One particular page is ...
follmer's user avatar
  • 123
3 votes
0 answers
445 views

Specifically for ReactJS and responsive frameworks that show/hide elements based on width like Bootstrap. Because ReactJS has a virtual DOM I am presuming doing the DOM manipulation is faster and in ...
Archimedes Trajano's user avatar
4 votes
1 answer
127 views

If I had a development workflow that supports SCSS and uses bootstrap. I can place bootstrap tags two ways... Inside the HTML: <div class="col-sm-3 offset-sm-9 col-xl-1 offset-xl-11"> Part of ...
Archimedes Trajano's user avatar
4 votes
3 answers
921 views

We are a small front-end dev-team working with 18 months of experience and recently we got in touch with a first major project, ie. a medium complexity back-office web app, but with lots and lots of ...
John's user avatar
  • 783
1 vote
1 answer
1k views

I am currently implementing WYSIWYG editor that will be available on the web, what are the main security issues I should tackle? The editor currently works that when user is done typing, the text gets ...
user259626's user avatar

1
2 3 4 5 6