Web: maska wygaszajaca wypelnienia wykresu przy prawej krawedzi okna
This commit is contained in:
@@ -132,6 +132,14 @@ function ChartBackdrop() {
|
||||
<stop offset="35%" stopColor="var(--chart-blue)" stopOpacity="0.08" />
|
||||
<stop offset="100%" stopColor="var(--chart-blue)" stopOpacity="0" />
|
||||
</linearGradient>
|
||||
<linearGradient id="chart-fade-x" x1="0" y1="0" x2="1" y2="0">
|
||||
<stop offset="0%" stopColor="#fff" />
|
||||
<stop offset="82%" stopColor="#fff" />
|
||||
<stop offset="100%" stopColor="#000" />
|
||||
</linearGradient>
|
||||
<mask id="chart-mask-x" maskUnits="userSpaceOnUse" x="0" y="0" width="1000" height="950">
|
||||
<rect x="0" y="0" width="1000" height="950" fill="url(#chart-fade-x)" />
|
||||
</mask>
|
||||
<clipPath id="chart-reveal">
|
||||
<rect ref={clipRef} x="0" y="0" width="0" height="950" />
|
||||
</clipPath>
|
||||
@@ -141,10 +149,11 @@ function ChartBackdrop() {
|
||||
</defs>
|
||||
<g clipPath="url(#chart-reveal)">
|
||||
<path
|
||||
d={`${CHART_PATH} L1000,700 L0,700 Z`}
|
||||
d={`${CHART_PATH} L1000,900 L0,900 Z`}
|
||||
fill="url(#chart-fill)"
|
||||
fillOpacity="0.3"
|
||||
stroke="none"
|
||||
mask="url(#chart-mask-x)"
|
||||
/>
|
||||
<path
|
||||
d={CHART_PATH}
|
||||
@@ -180,6 +189,7 @@ function ChartBackdrop() {
|
||||
fill="url(#chart-fill-2)"
|
||||
fillOpacity="0.3"
|
||||
stroke="none"
|
||||
mask="url(#chart-mask-x)"
|
||||
/>
|
||||
<path
|
||||
d={CHART_PATH2}
|
||||
|
||||
Reference in New Issue
Block a user