Xiaobian to share the METER degree balance how to change color in HTML5, I believe that most people don’t know much, so share this article to everyone, I hope everyone is reading this article. Big gain, below Let’s go find it!
The definition and usage of HTML5 Meter tag:
Tag definition metric. Used only for the metrics known to the maximum and minimum. For example: disk usage, correlation between query results, etc.
Note:Cannot be used as a schedule, a progress bar
52 OUT OF 10
Meter element represents a number of values within the predetermined range. There are 6 attributes of Meter elements! 1.Value Attribute: The actual value specifically expressed in the element. This attribute value defaults to 0, which can make a floating point fraction for this attribute.
30% What is METER element:
2.min attribute: Specifies the minimum minimum value when the specified range is specified, default 0, and the value set when setting this property cannot be less than 0. 3.max attribute: Specifies the maximum value to use when the specified range is specified, and if the value is less than the value of the value, the value of the min attribute is the maximum value. The default value of the MAX property is 1. 4.LOW attribute: The lower limit of the specified range must be less than or equal to the value of HIGH.5.High attribute: The upper limit of the specified range. If the property value is less than the value of the Low property, the value of the LOW attribute is the value of the high property, and if the value of this property is greater than the value of the max attribute, the value of the max property is the value of the value of HIGH.
6.OptimumUM Property: The best value attribute value must be in the min attribute value and MaBetween the X attribute value, it can be greater than the high attribute value.
HTML5 METER degree balance how to change color:
To change color in me, you need to use five values, namely MIN (minimum), max (Maximum), Low, High, Value and Optimum, where the first four values are divided into 3 intervals,
Green: When the value and optimum values are in one interval, it will present green.
Yellow: When Optimum is between High and Max, Value is between Low and High, it will show yellow
When Optimum is between Low and HiGH , The value value is between MIN and LOW, and it will appear yellow during HIGH and MAX.
When Optimum is between MIN and LOW, the value value will appear yellow between Low and HiGH. Red: When Optimum is between HIGH and MAX, the value value will be red when MIN and LOW are present.
When Optimum is between MIN and LOW, Value will present red between HIGH and MAX.
When Optimum is in the green area, Value will also present green
when Optimum is in the yellow area when optimum is in the yellow area. The whole will appear yellow
When Optimum is in the green area, the value value will present red
when Optimum is in the green area, the valu value In the middle green area is green
When Optimum is in the green area, the value value is yellow between MIN and LOW and between HIGH and MAX
When Optimum is When the green area,Value also presents green
when Optimum is in the yellow area when Optimum is in the yellow area, the entire value will present yellow
when Optimum When the green area, the value value will show a red
HTML 4.01 and HTML 5 in the red area:
The tag is a new tag in HTML 5.
The above is how METER degree balance in HTML5 changes all the contents of the color, thank you for reading! I believe everyone has a certain understanding, I hope to share the content of everyone, if you want to learn more knowledge, please pay attention to Tumi Yun Industry News Channel!