From 5041c34f9fb9f74a59099c7410aa392065f56930 Mon Sep 17 00:00:00 2001
From: Iajret Creature <122297233+Steals-The-PRs@users.noreply.github.com>
Date: Tue, 9 Apr 2024 01:12:08 +0300
Subject: [PATCH] [MIRROR] Fixes the color matrix editor (#2777)

* Fixes the color matrix editor (#82478)

## About The Pull Request

It was sending back stringified numbers as inputs. This came from a
typescript cleanup pr from sync (#82000) and was ultimately caused by
a... I think misunderstanding of how the color list works (#67967)

## Why It's Good For The Game

Works like a charm now, which is good cause I use it a lot

## Changelog
:cl:
fix: The color matrix editor now works properly again
/:cl:

* Fixes the color matrix editor

---------

Co-authored-by: NovaBot <154629622+NovaBot13@users.noreply.github.com>
Co-authored-by: LemonInTheDark <58055496+LemonInTheDark@users.noreply.github.com>
---
 tgui/packages/tgui/interfaces/ColorMatrixEditor.tsx | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/tgui/packages/tgui/interfaces/ColorMatrixEditor.tsx b/tgui/packages/tgui/interfaces/ColorMatrixEditor.tsx
index 897c43e6234..edf75dcf161 100644
--- a/tgui/packages/tgui/interfaces/ColorMatrixEditor.tsx
+++ b/tgui/packages/tgui/interfaces/ColorMatrixEditor.tsx
@@ -13,7 +13,7 @@ import { Window } from '../layouts';
 
 type Data = {
   mapRef: string;
-  currentColor: string[];
+  currentColor: number[];
 };
 
 const PREFIXES = ['r', 'g', 'b', 'a', 'c'] as const;
@@ -49,7 +49,7 @@ export const ColorMatrixEditor = (props) => {
                                 format={(value) => toFixed(value, 2)}
                                 onDrag={(value) => {
                                   let retColor = currentColor;
-                                  retColor[row * 4 + col] = `${value}`;
+                                  retColor[row * 4 + col] = value;
                                   act('transition_color', {
                                     color: retColor,
                                   });