{"id":2867,"date":"2024-11-10T11:15:26","date_gmt":"2024-11-10T03:15:26","guid":{"rendered":"https:\/\/fwq.ai\/blog\/2867\/"},"modified":"2024-11-10T11:15:26","modified_gmt":"2024-11-10T03:15:26","slug":"%e5%a6%82%e4%bd%95%e7%94%a8-css-paint-api-%e5%ae%9e%e7%8e%b0%e5%80%be%e6%96%9c%e7%9a%84%e6%96%91%e9%a9%ac%e7%ba%bf%e9%97%b4%e9%9a%94%e5%9c%86%e7%8e%af%ef%bc%9f","status":"publish","type":"post","link":"https:\/\/fwq.ai\/blog\/2867\/","title":{"rendered":"\u5982\u4f55\u7528 CSS Paint API \u5b9e\u73b0\u503e\u659c\u7684\u6591\u9a6c\u7ebf\u95f4\u9694\u5706\u73af\uff1f"},"content":{"rendered":"<p><img decoding=\"async\" src=\"https:\/\/img.php.cn\/upload\/article\/001\/246\/273\/173089841324947.jpg\" class=\"aligncenter\" title=\"\u5982\u4f55\u7528 CSS Paint API \u5b9e\u73b0\u503e\u659c\u7684\u6591\u9a6c\u7ebf\u95f4\u9694\u5706\u73af\uff1f\u63d2\u56fe\" alt=\"\u5982\u4f55\u7528 CSS Paint API \u5b9e\u73b0\u503e\u659c\u7684\u6591\u9a6c\u7ebf\u95f4\u9694\u5706\u73af\uff1f\u63d2\u56fe\" \/><\/p>\n<p><strong>\u5b9e\u73b0\u6591\u9a6c\u7ebf\u8fb9\u6846\u6837\u5f0f\uff1a\u63a2\u7a76  pnt api<\/strong><\/p>\n<p>\u672c\u6587\u5c06\u63a2\u7a76\u5982\u4f55\u4f7f\u7528 css paint api \u5b9e\u73b0\u503e\u659c\u7684\u6591\u9a6c\u7ebf\u95f4\u9694\u5706\u73af\u3002<\/p>\n<p><strong>\u95ee\u9898\uff1a<\/strong><\/p>\n<p>\u7ed9\u5b9a\u4e00\u4e2a\u6709\u591a\u4e2a\u5706\u5708\u7ec4\u6210\u7684\u6591\u9a6c\u7ebf\u56fe\u6848\uff0c\u5982\u4f55\u4f7f\u7528 css \u5b9e\u73b0\u503e\u659c\u7684\u6591\u9a6c\u7ebf\u95f4\u9694\u5706\u73af\uff1f<\/p>\n<p><strong>\u7b54\u6848\uff1a<\/strong><\/p>\n<p><span>\u7acb\u5373\u5b66\u4e60<\/span>\u201c\u201d\uff1b<\/p>\n<p><strong>\u4f7f\u7528 css paint api<\/strong><\/p>\n<p>css paint api \u662f\u4e00\u4e2a\u5f3a\u5927\u7684\u5de5\u5177\uff0c\u53ef\u4ee5\u8ba9\u4f60\u521b\u5efa\u81ea\u5b9a\u4e49\u7ed8\u56fe\u6548\u679c\u3002\u5b83\u5141\u8bb8\u4f60\u5b9a\u4e49\u81ea\u5df1\u7684\u5f62\u72b6\u548c\u6e10\u53d8\uff0c\u5e76\u4f7f\u7528\u5b83\u4eec\u6765\u7ed8\u5236\u5143\u7d20\u7684\u8fb9\u6846\u3002<\/p>\n<p><strong>\u793a\u4f8b\uff1a<\/strong><\/p>\n<pre>.zebra-container {\n  width: 200px;\n  height: 200px;\n  background: #fff;\n  border: 1px solid;\n  box-sizing: border-box;\n}\n\n.zebra-line {\n  paint-style: stroke;\n  stroke: #000;\n  stroke-width: 10px;\n  stroke-dasharray: 20 10;\n  transform: skewX(-20deg);\n}<\/pre>\n<p> \u767b\u5f55\u540e\u590d\u5236 <\/p>\n<p><strong>\u7ed3\u679c\uff1a<\/strong><\/p>\n<p>\u521b\u5efa\u4e00\u4e2a\u5305\u542b\u591a\u4e2a\u503e\u659c\u5706\u5708\u7684\u6591\u9a6c\u7ebf\u56fe\u6848\u3002<\/p>\n<p>\u4ee5\u4e0a\u5c31\u662f\u5982\u4f55\u7528 CSS Pnt API \u5b9e\u73b0\u503e\u659c\u7684\u6591\u9a6c\u7ebf\u95f4\u9694\u5706\u73af\uff1f\u7684\u8be6\u7ec6\u5185\u5bb9\uff0c\u66f4\u591a\u8bf7\u5173\u6ce8\u7c73\u4e91\u5176\u5b83\u76f8\u5173\u6587\u7ae0\uff01<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u5b9e\u73b0\u6591\u9a6c\u7ebf\u8fb9\u6846\u6837\u5f0f\uff1a\u63a2\u7a76 pnt api \u672c\u6587\u5c06\u63a2\u7a76\u5982\u4f55\u4f7f\u7528 css paint api \u5b9e\u73b0\u503e\u659c\u7684\u6591\u9a6c\u7ebf\u95f4\u9694\u5706\u73af\u3002 \u95ee\u9898\uff1a \u7ed9\u5b9a\u4e00\u4e2a\u6709\u591a\u4e2a\u5706\u5708\u7ec4\u6210\u7684\u6591\u9a6c\u7ebf\u56fe\u6848\uff0c\u5982\u4f55\u4f7f\u7528 css \u5b9e\u73b0\u503e\u659c\u7684\u6591\u9a6c\u7ebf\u95f4\u9694\u5706\u73af\uff1f \u7b54\u6848\uff1a \u7acb\u5373\u5b66\u4e60\u201c\u201d\uff1b \u4f7f\u7528 css paint api css paint api \u662f\u4e00\u4e2a\u5f3a\u5927\u7684\u5de5\u5177\uff0c\u53ef\u4ee5\u8ba9\u4f60\u521b\u5efa\u81ea\u5b9a\u4e49\u7ed8\u56fe\u6548\u679c\u3002\u5b83\u5141\u8bb8\u4f60\u5b9a\u4e49\u81ea\u5df1\u7684\u5f62\u72b6\u548c\u6e10\u53d8\uff0c\u5e76\u4f7f\u7528\u5b83\u4eec\u6765\u7ed8\u5236\u5143\u7d20\u7684\u8fb9\u6846\u3002 \u793a\u4f8b\uff1a .zebra-container { width: 200px; height: 200px; background: #fff; border: 1px solid; box-sizing: border-box; } .zebra-line { paint-style: stroke; stroke: #000; stroke-width: 10px; stroke-dasharray: 20 10; transform: skewX(-20deg); } \u767b\u5f55\u540e\u590d\u5236 \u7ed3\u679c\uff1a \u521b\u5efa\u4e00\u4e2a\u5305\u542b\u591a\u4e2a\u503e\u659c\u5706\u5708\u7684\u6591\u9a6c\u7ebf\u56fe\u6848\u3002 \u4ee5\u4e0a\u5c31\u662f\u5982\u4f55\u7528 [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[16],"tags":[],"class_list":["post-2867","post","type-post","status-publish","format-standard","hentry","category-16"],"_links":{"self":[{"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/posts\/2867","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/comments?post=2867"}],"version-history":[{"count":0,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/posts\/2867\/revisions"}],"wp:attachment":[{"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/media?parent=2867"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/categories?post=2867"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/tags?post=2867"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}