inuitcss / objects.flag Goto Github PK
View Code? Open in Web Editor NEW[DEPRECATED] [go to intuitcss/inuitcss] The flag object
Home Page: https://github.com/inuitcss/inuitcss
[DEPRECATED] [go to intuitcss/inuitcss] The flag object
Home Page: https://github.com/inuitcss/inuitcss
Having this link to your blog post somewhere on README.md would be helpful, but wasn't sure if you chose not to. http://csswizardry.com/2013/05/the-flag-object/
Using the direct child selector in .flag__img > img {}
means it is not possible to wrap the img in, say an <a>
link.
Remove the child selector to leave .flag__img img {}
There is a bug with .flag__body
in Webkit/Blink based browsers if its parent is table cell (actually display: table-cell
, I didn't check actual tables). It seems to take more space than it should. Let me demonstrate it here. If you check it in Firefox you will see how it should behave.
The fix is to remove width: 100%
from .flag__body
(or explicitly set it to width: auto
just to be sure) and set width: 1px
to .flag__img
. I have picked up the fix from an old(ish) article here. Here's what the author has to say about this:
By setting height/width:1px a normal cell will use the minimum amount of space to display its contents, leaving all unused space for the .Expand class cells with height/width:auto.
And here's a pen for the fix. This probably needs more testing, but it seems to not mess things up.
Hello everyone, hello Harry,
I was asking why images aren't width 100% when responsive, or at least why they aren't centered.
And also, wouldn't it be nice to have an image with a defined max-width, in order to be able to put bigger images without them to be huge in the desktop version ?
Thank you for your amazing work,
Something like :
@include media-query('palm') {
.flag__img > img {
width: 100%
}
}
.flag__img > img {
max-width: 200px;
}
I also don't understand why the $inuit-flag-collapse-at is not by default the 'palm' size.
Have a great day
- Thibaut
.flag--top and .flag--bottom should target only child .flag__img/.flag__body classes (via child selector combinator).
Is there a plan/workflow how pull request for new inuit would work? I'd be happy to contribute :)
Would you consider adding tiny and huge flags? Default values could be quarter/quadruple of $inuit-flag-gutter
, respectively.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.