我已尝试过所有内容,但我无法使用内联样式背景svg与Firefox一起使用,这适用于Chrome但不适用于Firefox。
<div style="display:flex;align-items: center;justify-content:space-between;height:100%;padding:1.25em;background-repeat: no-repeat;background-size: 100%;background-image:
url('data:image/svg+xml;utf8,<svg version="1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="1024" height="79"><defs><path id="a" d="M0 0h1024v79H0z"/></defs><clipPath id="b"><use xlink:href="#a" overflow="visible"/></clipPath><linearGradient id="c" gradientUnits="userSpaceOnUse" x1="-4" y1="35" x2="1024" y2="35"><stop offset="0" stop-color="#2377b8"/><stop offset="1" stop-color="#2e378e"/></linearGradient><path clip-path="url(#b)" fill="url(#c)" d="M-4-9h1028v88H-4z"/></svg>');">
<div style="display:flex;align-items:center;">
<h1 style="margin:0;color:white;font-weight:bold;font-size:1.8em;line-height:1;">
Title
</h1>
<h2 style="font-size:1.2em;line-height:1.5;color:white">
| Dashboard
</h2>
</div>
<div style="display:flex;align-items:center;">
<h1 style="margin:0;color:white;font-weight:bold;font-size:1.8em;line-height:1;margin-right:15px;">Location</h1>
<svg version="1" xmlns="http://www.w3.org/2000/svg" width="44" height="44"><circle cx="22" cy="22" r="22" fill="#fff"/>
<circle cx="22" cy="22" r="19" fill="#0b694f"/><circle cx="23" cy="22" r="9" fill="#f02e46"/></svg>
</div>
</div>
我在线查看了所有内容,但没有任何工作 -
提前致谢。
答案 0 :(得分:4)