Applied Visual Design Flashcards
What does text-align: justify; do?
Causes all lines of text except for the last line to meet the left and right edges of the line box
Explain how the box-shadow works
Applies one or more shadows to an element. Takes the value of
offset-x: How far to push the shadow horizontally from the element.
offset-y: How far to push the shadow vertically from the element.
blur-radius(optional)
spread-radius(optional)
and color in that order.
What does position relative do?
Tells you how CSS should move it relative to its current position.
What does position absolute do?
Locks an element in place relative to its parent container. Removes element from normal form of document so everything else ignores it. It will be locked relative to the closest position: relative. If it does not find one it will keep looking up the chain and default to the body tag.
What does float do?
It removes the element from the flow of the webpage and sets it either right or left of the containing parent element.
How does the z-index work?
Specify the order of how elements are stacked on one another. Must be a number and the higher the number , it moves up on the stack than those with lower numbers.
What’s one way to center a horizontal block element?
margin auto
What are complimentary colors? Examples?
When two colors are opposite each other on the wheel. When combined, they cancel each other out and create a gray color. Examples are red and cyan, green and magenta, blue and yellow.
What are secondary colors?
These colors are made when primary(Red, green, blue) mix. Cyan, magenta and yellow. These secondary colors compliment the primary color that was not used in its making. For example magenta is made with red and blue, and is the compliments green.
What are tertiary colors?
Result of combining a primary color with on its secondary colors. Red(primary) and yellow(secondary) mix to create orange(tertiary). This adds six more colors to a simple color wheel for a total of twelve.
What is hsl?
A way to define colors. H is for Hue which is the general color. S is for the saturation which is regarding how much gray is in it. A fully saturated 100% has no saturation in it, and l stands for light ranging from 0%(black) to 100%(white) with 50% being the normal color.
What are some things that can be done knowing hsl?
Mixing white with a pure hue creates a tint of that color, and adding black will make a shade. Alternatively, a tone is produced by adding gray or by both tinting and shading. The saturation percent changes the amount of gray and the lightness percent determines how much white or black is in the color. This is useful when you have a base hue you like, but need different variations of it.
Explain how linear gradient works
The first argument specifies the direction from which color transition starts - can be stated as a degree, where 90deg makes a horizontal gradient (from left to right) and 45deg makes a diagonal gradient (from bottom left to top right). The following arguments specify the order of colors used in the gradient. background: linear-gradient(90deg, red, yellow, rgb(204, 204, 255));
The ::before and ::after come after their specified element. What do they both need to exist?
The content property. If we’re not dealing with stuff like images then we can set it to an empty string such as content: “”.
What does @keyframes do?
Specifies what happens in the animation over a duration. If we compare it to a movie, 0% would be the opening scene and 100% would be the closing scene. Here is an example: #anim { animation-name: colorful; animation-duration: 3s; }
@keyframes colorful { 0% { background-color: blue; } 100% { background-color: yellow; } }