create rotated ribbons in css - css

how can i create a ribbon like this that sits on corner of my boxes and it is rotated too with css and without images.
i know that exits some tools and tutorials like this and this that makes ribbons easily with css.
but all of those are horizontal type while i want to create a rotated one.

Once you follow those tutorials to create a horizontal ribbon, use CSS3 Transform (Rotation) to rotate the ribbon: http://davidwalsh.name/css-transform-rotate

http://jsfiddle.net/R6jMH/ Have a look

Related

How do I create a line between two divs (or two points) in reactjs?

9 circles in a 3 x 3 grid with random lines on three of them connecting them to other circles (image)
I'm trying to more of less re-create the image above using react. The circles are div blocks and I have no clue how to go about drawing the lines that "connect" one circle to the other.
I tried using react-lineto, but it's simply not rendering anything when I use it. I can use the hr tag and use position absolute or something and just play around with where it's placed by toying with top and left props, but I don't think I'd be able to create diagonal lines.
Open to whatever packages or strategies you guys think could help me connect two dots (which are styled div blocks) with a line that could be vertical, horizontal, or diagonal.
Below is what I added to use react-lineto that didn't work. Straight from the documentation. I don't care to get react-lineto working as much as I just care to be able to accomplish this task in general.
<div className="A"></div>
<div className="B"><div/>
<LineTo from="A" to="B" />

How to make this type of shape in react

I want to create this shape in react. I am able to code some of the parts but the border is creating issues.
Image Link here
What I am able to produce
Yo can use z-index property to achieve it.Set the z-index of vertical line to higher number than horizontal line and make sure both overlap each other at there intersection point.

Creating alert icon with shadow in CSS

i am trying to create the following image using css.... so far i've got this after googling a bit http://jsfiddle.net/w9Zgc/ and i want to make the following shape..
is there any way this can be done... any help would be appreciated.. oh and i would like the shadow to be like the one here... http://jsfiddle.net/w9Zgc/
So I managed to create an icon that renders more or less the same in all current browsers. I had to use an extra useless span, unfortunately.
http://codepen.io/myajouri/full/nJDzl
The triangle is made of two parts:
the upper (triangular) part is a transformed (skewed and rotated) square with rounded corners.
the bottom of the triangle is the bottom part of a rectangle with rounded corners.
Both parts are cut and joint at certain places to form the triangular shape with rounded corners and shadows.

Highlight image regions on hover with CSS

What is the HTML CSS solution for highlighting specific areas of a map/floor plan like this?
http://www.centrecourtshopping.co.uk/store-info/
They use sprite image look here.
Basically, it works like that:
The map with dark-blue regions is completely static.
There is invisible layer on top of it made from small rectangular in their case <a> -- each corresponds to single dark-blue region and posses its its own id.
When cursor is placed over a rectangular with id x the sprite image is nicely aligned with its background (by setting CSS's background-position).
Do not think, this magic would be possible without using JavaScript.

Place grid over map using CSS?

I have a world map image. I would like to place a SQUARE GRID over the entire map. I would like each square (cell grid) to change via mouseover with a border color change and background color change.
The grid needs to be layered over the map, transparent except the borders (which is the grid).
Can I achieve this using CSS or there a better way to do this?
Many thanks.
Erik
I'd suggest using a CSS grid framework as an easy way to produce the grid layout. I'd go for this one as you can easily use create a grid with 0px gutters.
You will need to modify the CSS to make the grid absolute positioned so it sits over the top of your map.
Each element in the grid is a DIV so you can easily attach Javascript events to each one to allow users to control the map. If it's a simple colour change on hover then just use css.
You can make the grid transparent using css too: http://css-tricks.com/css-transparency-settings-for-all-broswers/

Resources