Css3 uses the transform attribute to create js elastic motion, css3transform
Copyright Disclaimer: This article is an original article by the blogger and cannot be reproduced without the permission of the blogger.
Yesterday, I wanted to build an enterprise website to implement an elastic sliding navigation menu, but I couldn't find a lot of JavaScript code. Later I wanted to use jquery to implement it. I will share the Code with you, for more information, see.
The HTML code is as follows:
The Code is as follows:
Copy code
The CSS code is as follows:
The Code is as follows:
Copy code
Body {font-size: 100%;
Script opening functionIn the latest version of Elasticsearch, the dynamic scripting feature is disabled by default based on security considerations (if not available). If disabled, the following error is reported when using the script:scripts oftype[inline], operation [update] and lang [groovy] are disabledYou can fully turn on the dynamic scripting feature in the Config/elasticsearch.yml file, and add the following code at the end:Script.inline:onScript.indexed:onScript.file:onAfter configurat
The first is to download Elasticsearch https://www.elastic.co/downloads, unzip;
Then downloaded the Chinese parser Ik,github search Elasticsearch-ik can find, Https://github.com/medcl/elasticsearch-analysis-ik
IK download down is an IK source code that needs to run maven to generate IK jar packages, different ES versions correspond to different jar packages, which are clearly stated on GitHub's homepage;
Locate the bin in the directory after ES decompression, execute the command install
Instance
Leave blank space around items in the
p
{
display : Flex Span class= "pun" style= "Color: #93a1a1" ";
justify - content : space - around
}
Effect Preview
Browser support
The number in the table represents the version number of the first browser that supports the property.
The number immediately following the-webkit-,-ms-or-moz-is the first version that supports the prefix attribute.
Properties
-color:#fcf;box-flex:2;-moz-box-flex:2;-webkit-box-flex:2;}To use Box-flex, the parent container must be defined as Display:box, and the browser must have its own private prefix, since there is currently no browser support for the Box-flex property. The container stator display:box the container as an inline element. In the example above, the parent container is divided into 5 parts, and three child elements are 1,2,2, that is, the value of Box-flex is the equal portion of it. So, Col_1 for 50
Copyright NOTICE: This article for Bo Master original article, without Bo Master permission not reproduced. CSS3 using transform attribute to make JS elastic motion
Details about the parabolic motion example of js elastic potential energy animation, and js Potential Energy
Parabolic motion: When the drag ends, we make the current element move horizontally + vertically at the same time.
In the same moving distance, we move the mouse fast, and the move method triggers less times. On the contrary, the moving speed is slow, the move method is triggered more times-> the browser will trigger each move action at a minim
Flexbox DetailedFlexbox appears to solve complex web layouts because of the flexibility of this layout. The child elements of the container can be arranged in any direction. This property is currently in an informal standard. The Flex layout model differs from the block and inline model layouts, and the layout calculations for the block and inline models depend on the block and inline flow direction, and the flex layout relies on the flex directions. Simply put: Flexbox is a layout module, not
Common Example 1. Center Alignment"Utf-8"> class="Flex-container"> class="Flex-item">1class="Flex-item">2class="Flex-item">3class="Flex-item">4class="Flex-item">5class="Flex-item">6Effect:2. Adaptive navigation Effect:Align vertically with center"Utf-8"> class="content"> isExtremely difficult to vertically align contentusingTraditional CSS without knowing exactlywhereYou want the item to appear. Typical page layouts for blog posts"Utf-8"> class="Post"> isMy first blog postclass="Post-meta">
you click on the Details page, the scroll bar position is cached and you can put it in the sessionstorage|localstorage. Of course, if you use the Vuex, you can directly put the values into the Vuex to manage;???? 4. When returning from the details page, at the same time to do this, the scrolltop value you have in the cache is re-assigned to the current DIV scroll bar???? 5.Ok, this is the way of thinking, is done.In Vue, specifically implementedI am using the Vuex to manage the scroll bar posit
Elastic search6.2.2 Implementation of search records query, similar to Sina Weibo, the same search record in the back of the time will cover the previous (main idea: keywords to heavy, and then sorted by time)Create an index first// My search PUT my_search{ "Settings": { "Number_of_replicas": 0 }, "mappings" : {"_doc" :{" Properties": {"user": {"type": "Integer"}, "word": {"type": "Keywo
This example describes the effect of the jquery implementation of the flexible pop-up menu hidden on the left. Share to everyone for your reference. Specifically as follows:
This is a hidden on the left of the elastic pop-up menu, from Taobao buckle down, but also as a JavaScript buffer animation of the typical tutorial. This flexible menu scalability is strong, in fact, not only can be made into a menu, but also layout some text mixed with the conte
Recently in writing a simple layout framework, in fact, the function is very similar. But the goal requirement is to use the simplest possible code to implement some required functions. Application in some cases requiring fast loading.
CSS Section
. flex-row,.flex{
Display:-webkit-flex;display:flex;
Flex-direction:row
}
. flex-col{
display:-webkit-flex;
Display:flex;
Flex-direction:column;
}
JavaScript section
. directive (' Flex ', [function () {return
{
restrict: ' A ',
scope:{'
This paper illustrates the ad code of JS to realize the elastic floating effect. Share to everyone for your reference. Specifically as follows:
Here to introduce a JS flexible floating advertising code, touch the edge of the Web browser will follow the direction of the elasticity of the automatic floating, and constantly drift on the Web page, floating advertising code is very early on the code, the use of a wide range, and as an advertisement, as if
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.