This article for everyone to share the first example: JS control div layer expansion, contraction effect.
css+js Implementation of a DIV layer expansion/folding effect Shrink
Cloud-dwelling community.
Effect Chart:
Second
No matter how annoying we are about the browser type prefix, we have to face it every day, and some things don't work. There are two ways to use these prefixes: in CSS (such as "-moz-") and in JS. There is a clever JavaScript script in a magical
When you write components, you sometimes want to encapsulate some of the CSS styles associated with component features in JS, which is more cohesive and convenient to change. JS Dynamic Insert CSS Two steps: Create 1, a Style object2. Add styles
One
Overview of common pseudo-classes for tags
A:link{color:blue} a:visited{color:red} A:hover{color:green} A:active{color:purple}
linkThis pseudo-class is active when there is
Use
hoverMovement change
pOf
margin-topCan make the small module up, while in the bottom of the small module two diagonally divided into two colors of the square, relative to the small module absolute positioning, you can create a simple
Sometimes in the process of writing CSS, some restrictions always do not work, which involves the CSS style overlay problems, as follows
#navigator { height:100%; width:200; Position:absolute; left:0; Border:solid 2 #EEE;}.
Css3d Summary
3d transform (3D variant) (rotate skew scale translate)
Basic knowledge
Perspective (Visual range, depth of field) Perspective-origin (viewpoint)Transfrom
(1) coordinates x y Z
(2) Deformation base point position transform-origin(3)
Priority of Style
Multiple styles (multiple styles): If the external style, inner style, and inline styles apply to the same element at the same time, this is the case for multiple styles.
In general, the priority is as follows:
(external style)
What is design mode?
There have been jokes, design patterns are used by engineers to show off with others, appear tall, and some people say, not design mode useless, you have not been able to understand it, will use it.
Let's take a look at the
Line-height represents the row height, which is the distance between the two lines of text baselines.
inline box (inline elements)--Anonymous inline boxes (content area/text/inline box), including, in turn, a row box, multiple behaviors more than
Display:none and Visibility:hidden are all features that hide an element on a webpage, but they are different, and after experimenting, I find that using the Visibility:hidden property makes the object invisible. However, the object's space in the
As I mentioned before, each element in the document tree is just a rectangular box. These boxes have a background layer, which can be completely transparent or other colors, or it can be a picture. This background layer is controlled by 8 CSS
Background
Since the advent of CSS, the basic grammar and core mechanism has not changed in nature, and its development is almost entirely on the expressive level of ascension. The first CSS in the Web page function is only auxiliary decoration,
Today, I write the CSS style, which used the tag, set a series of effects after the run, found that the location and settings are discrepancies. Open the check on Chrome and find the following paragraph in the label's styles bottom:
UL, menu,
A detailed explanation of the usage of user-select in CSS3
The User-select property is a new property of CSS3 that sets whether the user can select text. Can be used for all elements except replacement elements, the following is a description
Centering has always been a typical complaint in CSS. Why is it so hard to get it done? So someone was laughed at. I think the problem is not that there is no way to do it, but depending on the situation, there are many different ways, but it is
Clear with empty tags
. clr {clear:both;}
Left
Right
Using the Overflow property
#layout {overflow:auto; zoom:1;}
Left
Right
Use: After (non IE browser)
#layout: after{
Display:block;
Clear:both; Content: "";
Visibility:hidden; height:0;
}
Objective
If you are interested in CSS preprocessor, then this article may be a good fit for you.
Beginner CSS preprocessor, in fact, I do not quite understand why need to use this kind of thing, and then want to understand one thing, everything is
Understand the Function. prototype. bind method in javascript, prototype. bind
When we are new to Javascript, we may not need to worry about function binding, but when we need to keep the context object this in another function, we will encounter
The latest 15 beautiful HTML photography website templates in 2017 and the 2017 Template
Photography is an art that requires a lot of patience and effort to capture those wonderful moments. If you are a passionate photographer and want to build a
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.
A Free Trial That Lets You Build Big!
Start building with 50+ products and up to 12 months usage for Elastic Compute Service