Search

Nalezeno "units": 164

Turning a Fixed-Size Object into a Responsive Element


I was in a situation recently where I wanted to show an iPhone on a website. I wanted users to be able to interact with an application demo on this “mock” phone, so it had to be rendered in CSS, not an image. I found a great library called marvelapp/devices.css. The library implemented the device...

`lh` and `rlh` units


There’s some new units I was totally unaware of from the Level 4 spec for CSS values! The lh unit is “equal to the computed value of line-height” and rlh is the same only of the root element (probably the <html> element) rather than the current element. Why would that...

CSS Viewport Units


Deep dive from Ahmad. I like the coverage of vmin and vmax, which I think I don't reach for as often as I should. I'm thinking that if you are doing something highly directional (e.g. a full bleed trick), then directly using vw is necessary. On the other hand, if you're doing a calculation where...

How Do You Do max-font-size in CSS?


CSS doesn't have max-font-size, so if we need something that does something along those lines, we have to get tricky. Why would you need it at all? Well, font-size itself can be set in dynamic ways. For example, font-size: 10vw;. That's using "viewport units" to size the type, which will...

Tokyo-Based Zigmabit Offers Mining Rigs for Homes and Offices


Cryptocurrency mining develops rapidly like any high tech sector. Improvements in the hardware and auxiliary systems make it possible to design mining rigs that are more compact and silent than they used to be, while also profitable to run. Zigmabit is a manufacturer that assembles units suitable...

Is it better to use ems/rems than px for font-size?


The answer used to be absolutely yes because, if you used px units, you prevented the text from being resized by the user at all. But browser zoom is the default method for making everything bigger (including text) these days and it works great even if you use px. But... Kathleen McMahon really...

Chicago Company Mines at Oil Wells, Educates Producers About Bitcoin


Utilizing stranded gas to power bitcoin mining rigs at oil and gas wells is a promising business opportunity. It is profitable for all participating parties and beneficial for the environment. Not without challenges, this young industry is growing in energy-rich North America. Several companies...

Simplified Fluid Typography


Fluid typography is the idea that font-size (and perhaps other attributes of type, like line-height) change depending on the screen size (or perhaps container queries if we had them). The core trickery comes from viewport units. You can literally set type in viewport units (e.g. font-size: 4vw)...

Canadian Company Commissions 3 Bitcoin Mining Units to Restart Oil Well


A nascent industry utilizing flared gas to power bitcoin mining units has been developing over the past year or so, in symbiosis with the oil and gas industry in North America. Companies providing services in this promising niche continue to install mobile datacenters at oil wells in the U.S....

Some Things You Oughta Know When Working with Viewport Units


David Chanin has a quickie article summarizing a problem with setting an element's height to 100vh in mobile browsers and then also positioning something on the bottom of that. Summarized in this graphic: The trouble is that Chrome isn't taking the address bar (browser chrome) into account when...

Bitmain Launches Next Gen Miner as Bitcoin Hashrate Touches 100 Exahash


Last Thursday the China-based mining rig manufacturer Bitmain announced the launch of two new Antminers that offer hashrates between 53 to 64 terahash per second (TH/s). When the Antminer sale started on Monday, first batch devices sold extremely fast and Bitmain expects to deliver units...

Using a PostCSS function to automate your responsive workflow


A little while back, you might have bumped into this CSS-Tricks article where I described how a mixin can be used to automate responsive font sizes using RFS. In its latest version, v9, RFS is capable of rescaling any value for value for any CSS property with px or rem units, like margin, padding...

Bounce Element Around Viewport in CSS


Let's say you were gonna bounce an element all around a screen, sorta like an old school screensaver or Pong or something. You'd probably be tracking the X location of the element, increasing or decreasing it in a time loop and — when the element reached the maximum or minimum value —...

From Booze to Bitcoin Mining – Why Violent Prohibition Is Always Harmful


Stories continue to emerge about newly discovered illegal mining operations being busted by state and corporate authorities. Just last week Iranian media reported the seizure of 177 Bitcoin mining units worth over $270,000 being smuggled via truck in the Arak region. On July 31, Russia’s...

CSS prefers-reduced-motion Media Query


When I started in the web development industry, media queries were limited — screen and print were the two media queries I was most often using. More than a decade later, media queries have advanced to various screen units, feature checking, and even color scheme preference. I’ve been...

Designing An Aspect Ratio Unit For CSS


Rachel Andrew says that the CSS Working Group designed an aspect ration unit at a recent meeting. The idea is to find an elegant solution to those times when we want the height of an element to be calculated in response to the width of the element, or vice versa. Say, for example, we have a grid...

Nahoru
Tento web používá k poskytování služeb a analýze návštěvnosti soubory cookie. Používáním tohoto webu s tímto souhlasíte. Další informace