doormat is the result of exploring different content traversal styles
This Pen uses: HTML, Stylus, CoffeeScript, and CoffeeScript
Originally posted 2016-06-16 01:30:10. Republished by Blog Post Promoter
Created [to answer a SO question](https://stackoverflow.com/questions/41658552/how-to-create-a-7-character-underline-input-text-field-in-html-and-cssscreensho/41661432#41661432). Try deleting and writing something else in the `input` field.
It uses [**the `ch` unit**](https://developer.mozilla.org/en-US/docs/Web/CSS/length#ch) whose width is the width of the `0` character. It also assumes the font in the `input` field is a monospace one so that all characters have the same width.
So the width for every character is always `1ch`. The gap between the characters is taken to be `.5ch`. This is the value we set for `letter-spacing`. The `width` of the `input` is the number of characters times the sum between the letter width (`1ch`) and the gap width (`.5ch`). So that's `7*(1ch + .5ch) = 7*1.5ch = 10.5ch`.
We remove the actual `border` of the `input` and we set a fake one using a `repeating-linear-gradient`. The dash (`dimgrey`) goes from `0` to `1ch` and the gap (`transparent`) starts immediately after the dash and goes to `1.5ch`.
It's attached to the left and the bottom of the input – this is the `background-position` component (`0%` horizontally and `100%` vertically).
It spreads across the entire input horizontally (`100%`) and is `2px` tall – this is the `background-size` component of the `background`.
This Pen uses: HTML, SCSS, Babel, and Babel
Every week users submit a lot of interesting stuff on our sister site Webdesigner News, highlighting great content from around the web that can be of interest to web designers.
The best way to keep track of all the great stories and news being posted is simply to check out the Webdesigner News site, however, in case you missed some here’s a quick and useful compilation of the most popular designer news that we curated from the past week.
Note that this is only a very small selection of the links that were posted, so don’t miss out and subscribe to our newsletter and follow the site daily for all the news.
Want more? No problem! Keep track of top design news from around the web with Webdesigner News.
|LAST DAY: 30 Sparkling Glitter Brushes from The Artifex Forge – only $7.50!||
MailChimp’s annual report is a fun retro celebration of shapes and patterns. Our pick this week.
Some hot new techniques for speeding up websites by Filament Group.
Hélio Dolores explains how real-time communication with WebSockets and optical illusions with CSS3 create a stunning, magical effect.
A great project by Ronik where you can take a virtual Winter ride around New York.
Jon Kantner’s genius demo that shows how problematic icon fonts can be.
A dialog box UX pattern that is worth commiting to.
A set of 40 super-cute and versatile clothing icons made by Creativebin for Smashing Magazine.
A standalone, stateless, dual quaternion based skeletal animation system that aims to give the user a flexible module for managing skeletal animations across different 3D models and bone groups. Made by Chinedu Francis Nwafili.
A little library for graceful CSS animations especially useful for loading behavior by Tommy Marshall.
Jon Moore shows a powerful Sketch technique that can save lots of time designing.
An article on the importance of the social and societal impact of product and their power to transform our society.