-
Notifications
You must be signed in to change notification settings - Fork 446
refactor/tweak: TGUI5 #6829
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
dageavtobusnick
wants to merge
36
commits into
ss220-space:master220
Choose a base branch
from
dageavtobusnick:tgui5
base: master220
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
refactor/tweak: TGUI5 #6829
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
javascript
Pull requests that update Javascript code
Merge Conflict
This doesn't seem right
TGUI
Affects TGUI
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Описание
Сделано следующее:
Замена inferno на react, с последующем обновлением реакта (не до react 19)
Замена useLocalState на useState
Обновление компонентов и кора до состояния, близкого к состоянию tgui-core до отказа от 516
Все js файлы заменены на ts и tsx, с сопутствующим рефактором.
Заменен тгуи сей на версию для 516.
Заменен babel плагин на swc.
Поправлены и почищены от мусора многие интерфейсы, а так же исправлено несколько старых ошибок.
Убран старый компонент ImageButton. Все заменено на TS версию, которая теперь является ImageButton.
Убраны средства совместимости тгуи с IE. Их поддержка излишне затруднительна.
Добавлено предупреждение для тех, кто заходит на 515 с рекомендацией обновиться.
Обновлен yarn.
Пофикшена проблема со статтерами на 516. Для тех, у кого останутся проблемы добавлена опция отключения сохранения чата в хранилище.
Много мелких изменений интерфейсов и настроек, которые произошли вследствие данных изменений.
Использован код со следующих пр-ов:
tgstation/tgstation#74638
tgstation/tgstation#61081
tgstation/tgstation#74547
tgstation/tgstation#79877
tgstation/tgstation#79894
tgstation/tgstation#79898
tgstation/tgstation#80430
ParadiseSS13/Paradise#26952
tgstation/tgstation#80276
tgstation/tgstation#80616
tgstation/tgstation#80656
tgstation/tgstation#80195
tgstation/tgstation#80249
tgstation/tgstation#80368
tgstation/tgstation#80291
tgstation/tgstation#90608
ParadiseSS13/Paradise#29100
ParadiseSS13/Paradise#29078
ParadiseSS13/Paradise#29193
А так же множество кода с https://github.com/tgstation/tgui-core и https://github.com/tgstation/tgstation, явные пр-ы которого выделить трудно.
Причина создания ПР / Почему это хорошо для игры
Использование реакта открывает больше возможностей для создания собственных интерфейсов, а так же порта интерфейсов с других билдов.
Перевод всего на typescript позволяет обнаружить некоторые баги еще на стадии компиляции, чего при использовании js нельзя сделать в полной мере.
swc банально быстрее и современнее babel в плане скорости сборки.
Тесты
Запустил, проверил все интерфейсы, которые смог использовать без бд и игроков(примерно 90%). На них на 516 все работает хорошо.