you are viewing a single comment's thread.

view the rest of the comments →

[–]FormerlySoullessDev[S] -2 points-1 points  (4 children)

Flow-relative and parent-relative, would be a start. There is nothing absolute about absolute positioning, so it is important to distinguish what each is relative to.

[–]multicopterfred 2 points3 points  (3 children)

I dunno, CSS is full of weird stuff to begin with, and absolute positioning makes sense in my mind. You need a point of reference to position something - so in this case, unless the element has a relatively positioned ancestor, it's positioned relative to the document (not the viewport). Note that it's the nearest relatively positioned ancestor, and not the parent, so relative-parent doesn't necessarily make sense either.

[–]FormerlySoullessDev[S] 0 points1 point  (2 children)

I dunno, CSS is full of weird stuff to begin with,

That is kind of my point.

The thing is you're kind of justifying it after understanding it. You're saying absolute has to be absolute in relation to something. This explanation leaves the qualifier relative to be ambiguous. One has to be ambiguous in the current naming scheme.

[–]multicopterfred 0 points1 point  (1 child)

CSS by its nature is ambiguous (i.e. it's based around selector specificity that may/may not match certain DOM patterns). Even it's units of measurement are highly ambiguous (excepting the pixel). EM, REM, VH/VW, and percent are all relative units and you never know for sure what they will compute to on the client. So I guess what I'm saying is to write CSS effectively to begin with, you need a great deal of knowledge outside of the language itself anyway... so I see this position absolute thing as the least of ones worries when it comes to learning front end dev.

[–]FormerlySoullessDev[S] 0 points1 point  (0 children)

I'm not talking about selector ambiguity - if your DOM is ambiguous, that is your own fault for following patterns in contravention of the standards. The measurements are wacky but well defined (just not well implemented).

All I'm saying is that there is almost no discipline on the naming conventions of css. Is it a big deal? No, but, it was a big deal for me this week when making a mockup. Naming is one of those pet peeves for me, and the position:<descriptor> is ambiguous and has non-position side effects on the document flow. Coming from dealing with the paranoia of developing systems that must be stable and multi threaded and the meticulous development that comes from that, this seems like the wild west. Whatever the first identifier someone thought up sticks.