Skip to content

Commit

Permalink
Replaced Linear Gardient with Radial for editor selected key
Browse files Browse the repository at this point in the history
Signed-off-by: AlexDygma <[email protected]>
  • Loading branch information
AlexDygma committed Apr 19, 2021
1 parent 7161d12 commit f47c1f8
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 22 deletions.
21 changes: 10 additions & 11 deletions src/api/hardware-dygma-raise-ansi/components/Keymap-ANSI.js
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,7 @@ class KeymapANSI extends React.Component {
let stroke = (row, col) =>
isSelected(row, col) ? "url('#selected-gradient')" : "#b3b3b3";

let getStrokeWidth = (row, col) => (isSelected(row, col) ? "4.0" : "1.5");
let getStrokeWidth = (row, col) => (isSelected(row, col) ? "3.0" : "1.5");

const colormap =
this.props.colormap ||
Expand Down Expand Up @@ -428,30 +428,29 @@ class KeymapANSI extends React.Component {
className={this.props.className || "layer"}
>
<defs>
<linearGradient
<radialGradient
id="selected-gradient"
x1="80%"
y1="0%"
x2="40%"
y2="100%"
cx="1.6982"
cy="1.3057"
r="129.5064"
>
<stop offset="0%" stopColor="#FF2339">
<stop offset="0" stopColor="#ffeb3b">
<animate
attributeName="stop-color"
values="#FF2339; #79009d; #FF2339"
values="#ffeb3b; #79009d; #ffeb3b"
dur="1s"
repeatCount="indefinite"
></animate>
</stop>
<stop offset="100%" stopColor="#79009d">
<stop offset="1" stopColor="#79009d">
<animate
attributeName="stop-color"
values="#79009d; #FF2339; #79009d"
values="#79009d; #ffeb3b; #79009d"
dur="1s"
repeatCount="indefinite"
></animate>
</stop>
</linearGradient>
</radialGradient>
</defs>
<path
id="neuron_outline"
Expand Down
21 changes: 10 additions & 11 deletions src/api/hardware-dygma-raise-iso/components/Keymap-ISO.js
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,7 @@ class KeymapISO extends React.Component {
let stroke = (row, col) =>
isSelected(row, col) ? "url('#selected-gradient')" : "#b3b3b3";

let getStrokeWidth = (row, col) => (isSelected(row, col) ? "4.0" : "1.5");
let getStrokeWidth = (row, col) => (isSelected(row, col) ? "3.0" : "1.5");

const colormap =
this.props.colormap ||
Expand Down Expand Up @@ -429,30 +429,29 @@ class KeymapISO extends React.Component {
className={this.props.className || "layer"}
>
<defs>
<linearGradient
<radialGradient
id="selected-gradient"
x1="80%"
y1="0%"
x2="40%"
y2="100%"
cx="1.6982"
cy="1.3057"
r="129.5064"
>
<stop offset="0%" stopColor="#FF2339">
<stop offset="0" stopColor="#ffeb3b">
<animate
attributeName="stop-color"
values="#FF2339; #79009d; #FF2339"
values="#ffeb3b; #79009d; #ffeb3b"
dur="1s"
repeatCount="indefinite"
></animate>
</stop>
<stop offset="100%" stopColor="#79009d">
<stop offset="1" stopColor="#79009d">
<animate
attributeName="stop-color"
values="#79009d; #FF2339; #79009d"
values="#79009d; #ffeb3b; #79009d"
dur="1s"
repeatCount="indefinite"
></animate>
</stop>
</linearGradient>
</radialGradient>
</defs>
<path
id="neuron_outline"
Expand Down

0 comments on commit f47c1f8

Please sign in to comment.