सीएसएस मुखौटा-स्थिति संपत्ति
उदाहरण
मुखौटा परत छवि की स्थिति को केंद्र में सेट करें:
.mask1 {
-webkit-mask-image: url(w3logo.png);
mask-image: url(w3logo.png);
-webkit-mask-size: 50%;
mask-size: 50%;
-webkit-mask-repeat: no-repeat;
mask-repeat: no-repeat;
-webkit-mask-position: center;
mask-position: center;
}
नीचे और अधिक "इसे स्वयं आज़माएं" उदाहरण।
परिभाषा और उपयोग
mask-position
संपत्ति एक मुखौटा छवि (मुखौटा स्थिति क्षेत्र के सापेक्ष) की प्रारंभिक स्थिति निर्धारित करती है ।
युक्ति: डिफ़ॉल्ट रूप से, एक मुखौटा छवि किसी तत्व के ऊपरी-बाएँ कोने पर रखी जाती है, और लंबवत और क्षैतिज दोनों तरह से दोहराई जाती है।
डिफ़ॉल्ट मान: | 0% 0% |
---|---|
विरासत में मिला: | नहीं |
एनिमेटेबल: | नहीं। एनिमेटेबल के बारे में पढ़ें |
संस्करण: | CSS3 |
जावास्क्रिप्ट सिंटैक्स: | ऑब्जेक्ट .style.maskPosition = "100px केंद्र" |
ब्राउज़र समर्थन
तालिका में संख्याएं पहले ब्राउज़र संस्करण को निर्दिष्ट करती हैं जो पूरी तरह से संपत्ति का समर्थन करता है।
-वेबकिट के बाद की संख्याएं- उपसर्ग के साथ काम करने वाले पहले संस्करण को निर्दिष्ट करें।
Property | |||||
---|---|---|---|---|---|
mask-position | 4.0 -webkit- | 79.0 -webkit- | 53.0 | 4.0 -webkit- | 15.0 -webkit- |
सीएसएस सिंटेक्स
mask-position: value;
सम्पत्ति की कीमत
Value | Description |
---|---|
left top left center left bottom right top right center right bottom center top center center center bottom |
If you only specify one keyword, the other value will be "center" |
x% y% | The first value is the horizontal position and the second value is the vertical. The top left corner is 0% 0%. The right bottom corner is 100% 100%. If you only specify one value, the other value will be 50%. Default value is: 0% 0% |
xpos ypos | The first value is the horizontal position and the second value is the vertical. The top left corner is 0 0. Units can be pixels (0px 0px) or any other CSS units. If you only specify one value, the other value will be 50%. You can mix % and positions |
initial | Sets this property to its default value. Read about initial |
inherit | Inherits this property from its parent element. Read about inherit |
और ज्यादा उदाहरण
उदाहरण
मुखौटा परत छवि की स्थिति को दाएं निचले कोने पर सेट करें:
.mask1 {
-webkit-mask-image: url(w3logo.png);
mask-image: url(w3logo.png);
-webkit-mask-size: 50%;
mask-size: 50%;
-webkit-mask-repeat: no-repeat;
mask-repeat: no-repeat;
-webkit-mask-position: 100% 100%;
mask-position: 100% 100%;
}
संबंधित पृष्ठ
सीएसएस संदर्भ: मुखौटा-छवि संपत्ति
CSS संदर्भ: मास्क-मोड गुण
सीएसएस संदर्भ: मुखौटा-मूल संपत्ति
CSS संदर्भ: मास्क-रिपीट प्रॉपर्टी
सीएसएस संदर्भ: मुखौटा-आकार की संपत्ति
सीएसएस ट्यूटोरियल: सीएसएस मास्किंग