diff --git a/Assets/AddressableAssetsData/AddressableAssetSettings.asset b/Assets/AddressableAssetsData/AddressableAssetSettings.asset
index 8cf3716..6ecdd23 100644
--- a/Assets/AddressableAssetsData/AddressableAssetSettings.asset
+++ b/Assets/AddressableAssetsData/AddressableAssetSettings.asset
@@ -15,7 +15,7 @@ MonoBehaviour:
m_DefaultGroup: e44b9e080d5ce064aa2fa777858a4f4d
m_currentHash:
serializedVersion: 2
- Hash: 56525d59520acb454a65423041453959
+ Hash: 00000000000000000000000000000000
m_OptimizeCatalogSize: 0
m_BuildRemoteCatalog: 0
m_CatalogRequestsTimeout: 0
@@ -61,33 +61,33 @@ MonoBehaviour:
m_overridePlayerVersion: '[UnityEditor.PlayerSettings.bundleVersion]'
m_GroupAssets:
- {fileID: 11400000, guid: d3e4e2c785073483c86cd9a06692f3c6, type: 2}
+ - {fileID: 11400000, guid: 822373f07486e4961ad948a50f72c614, type: 2}
+ - {fileID: 11400000, guid: 88ac0f98d3c2144109d59527052380dd, type: 2}
- {fileID: 11400000, guid: 8212e995c32ff449e85de4dfe678db4b, type: 2}
- {fileID: 11400000, guid: fdc4e67966ae941b599f8185e4553a13, type: 2}
- - {fileID: 11400000, guid: 1d5d364f9b5614dda825698a1a9cacfc, type: 2}
- {fileID: 11400000, guid: 076ecdf1095cf634b9d1ad0e46628cb9, type: 2}
- {fileID: 11400000, guid: 1e8453572c1142e439fefd36fdc32edc, type: 2}
- {fileID: 11400000, guid: 6ed67ed2b9fd82e4ea84b4d172aa92a1, type: 2}
- - {fileID: 11400000, guid: 0bd5c69caa78b4304a0e8a4d7c0e8899, type: 2}
- {fileID: 11400000, guid: d02e1cb0cd3bc43b3aaec26eba2ba2cf, type: 2}
- - {fileID: 11400000, guid: 61a5e655eb50249a58ccac1fd1d57832, type: 2}
- {fileID: 11400000, guid: 632636d5d8f7749f5ae1a36952f924aa, type: 2}
+ - {fileID: 11400000, guid: a235547bd437e40ba88cfee73fe6afef, type: 2}
+ - {fileID: 11400000, guid: 0bd5c69caa78b4304a0e8a4d7c0e8899, type: 2}
+ - {fileID: 11400000, guid: a66040e7a1f0f492482442d8fe463828, type: 2}
- {fileID: 11400000, guid: ef4f88f40627e5f4dbf786b246262c08, type: 2}
- {fileID: 11400000, guid: 2e6a1ccb6d000534bb7b714e26951e06, type: 2}
- {fileID: 11400000, guid: d9d8d49aee1153349a4c13e0c7145ccb, type: 2}
- {fileID: 11400000, guid: f1ce45fc8bef3994cbc2c727f329cafc, type: 2}
- - {fileID: 11400000, guid: 5d94c7a0bd4034305bf30b43a02e4291, type: 2}
- {fileID: 11400000, guid: cc2b1da5e78ca6643b743c2e41cde192, type: 2}
- {fileID: 11400000, guid: d0f648b5a1d3347e0ace6b74d037732e, type: 2}
+ - {fileID: 11400000, guid: 5d94c7a0bd4034305bf30b43a02e4291, type: 2}
- {fileID: 11400000, guid: e916d8c94acefab45a62ee54e418ec7d, type: 2}
+ - {fileID: 11400000, guid: 1d5d364f9b5614dda825698a1a9cacfc, type: 2}
- {fileID: 11400000, guid: d086f583b7a0cae428375319aff9253a, type: 2}
- {fileID: 11400000, guid: ae26ffebd88c8b2428add93c4389c8f3, type: 2}
- - {fileID: 11400000, guid: a66040e7a1f0f492482442d8fe463828, type: 2}
- - {fileID: 11400000, guid: 88ac0f98d3c2144109d59527052380dd, type: 2}
+ - {fileID: 11400000, guid: 61a5e655eb50249a58ccac1fd1d57832, type: 2}
- {fileID: 11400000, guid: 4fef78bd155109a48b208e4d8010df17, type: 2}
- {fileID: 11400000, guid: c3c7be9bc48a7134b83d92baf56af267, type: 2}
- {fileID: 11400000, guid: 1c773518c5ef54385a29ab964c7e4b73, type: 2}
- - {fileID: 11400000, guid: 822373f07486e4961ad948a50f72c614, type: 2}
- - {fileID: 11400000, guid: a235547bd437e40ba88cfee73fe6afef, type: 2}
- {fileID: 11400000, guid: d0f0cb20d7ec1164b95f42151d183027, type: 2}
- {fileID: 11400000, guid: 81731497086aa9b4795b0fb065535a3b, type: 2}
- {fileID: 11400000, guid: de95fc190ea0b44cdb9ae7724f4ef834, type: 2}
diff --git a/Assets/Localization/String Tables/Game Text_ar.asset b/Assets/Localization/String Tables/Game Text_ar.asset
index 541f11e..009cb6d 100644
--- a/Assets/Localization/String Tables/Game Text_ar.asset
+++ b/Assets/Localization/String Tables/Game Text_ar.asset
@@ -163,9 +163,8 @@ MonoBehaviour:
m_Items: []
- m_Id: 45343066714112
m_Localized: "\u0627\u0646\u062A\u0647\u062A \u0627\u0644\u0644\u0639\u0628\u0629!\\n\\n\u0644\u0642\u062F
- \u0648\u062C\u062F\u062A {orderedWordCount:plural:{} \u0643\u0644\u0645\u0629
- |{} \u0643\u0644\u0645\u0627\u062A} \u0645\u0646 \u0625\u062C\u0645\u0627\u0644\u064A
- {totalWordCount}"
+ \u0648\u062C\u062F\u062A {orderedWordCount} \u0643\u0644\u0645\u0627\u062A
+ \u0645\u0646 \u0625\u062C\u0645\u0627\u0644\u064A {totalWordCount}"
m_Metadata:
m_Items:
- rid: 2216566543976235776
diff --git a/Assets/Resources/UITk/IntroView.uxml b/Assets/Resources/UITk/IntroView.uxml
index 3e5751c..80e73c3 100644
--- a/Assets/Resources/UITk/IntroView.uxml
+++ b/Assets/Resources/UITk/IntroView.uxml
@@ -1,4 +1,3 @@
-
diff --git a/Assets/Resources/UITk/MainView.uxml b/Assets/Resources/UITk/MainView.uxml
deleted file mode 100644
index b8f6252..0000000
--- a/Assets/Resources/UITk/MainView.uxml
+++ /dev/null
@@ -1,280 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/Assets/Resources/UITk/Splash.uxml b/Assets/Resources/UITk/Splash.uxml
deleted file mode 100644
index c46f33a..0000000
--- a/Assets/Resources/UITk/Splash.uxml
+++ /dev/null
@@ -1,4 +0,0 @@
-
-
-
-
diff --git a/Assets/Resources/UITk/Themes/Common/CommonStyle.Rules.uss b/Assets/Resources/UITk/Themes/Common/CommonStyle.Rules.uss
deleted file mode 100644
index 1161b08..0000000
--- a/Assets/Resources/UITk/Themes/Common/CommonStyle.Rules.uss
+++ /dev/null
@@ -1 +0,0 @@
-VisualElement {}
\ No newline at end of file
diff --git a/Assets/Resources/UITk/Themes/Common/CommonStyle.tss b/Assets/Resources/UITk/Themes/Common/CommonStyle.tss
deleted file mode 100644
index 00b66ce..0000000
--- a/Assets/Resources/UITk/Themes/Common/CommonStyle.tss
+++ /dev/null
@@ -1 +0,0 @@
-@import url("CommonStyle.Rules.uss")
\ No newline at end of file
diff --git a/Assets/Resources/UITk/Themes/GreenStyle.meta b/Assets/Resources/UITk/Themes/Design System Files.meta
similarity index 77%
rename from Assets/Resources/UITk/Themes/GreenStyle.meta
rename to Assets/Resources/UITk/Themes/Design System Files.meta
index 3140492..1b295f0 100644
--- a/Assets/Resources/UITk/Themes/GreenStyle.meta
+++ b/Assets/Resources/UITk/Themes/Design System Files.meta
@@ -1,5 +1,5 @@
fileFormatVersion: 2
-guid: 2ab7798c56e0a4f4e8abbf4f1abe6f7b
+guid: 180a1520f89f54e0f8ad216887efbaae
folderAsset: yes
DefaultImporter:
externalObjects: {}
diff --git a/Assets/Resources/UITk/Themes/Design System Files/DesignSystemTemplate.uxml b/Assets/Resources/UITk/Themes/Design System Files/DesignSystemTemplate.uxml
new file mode 100644
index 0000000..87160ae
--- /dev/null
+++ b/Assets/Resources/UITk/Themes/Design System Files/DesignSystemTemplate.uxml
@@ -0,0 +1,13 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Assets/Resources/UITk/Splash.uxml.meta b/Assets/Resources/UITk/Themes/Design System Files/DesignSystemTemplate.uxml.meta
similarity index 86%
rename from Assets/Resources/UITk/Splash.uxml.meta
rename to Assets/Resources/UITk/Themes/Design System Files/DesignSystemTemplate.uxml.meta
index d4027f4..39fefac 100644
--- a/Assets/Resources/UITk/Splash.uxml.meta
+++ b/Assets/Resources/UITk/Themes/Design System Files/DesignSystemTemplate.uxml.meta
@@ -1,5 +1,5 @@
fileFormatVersion: 2
-guid: c496c79f5fb054cdd802ac2a0a3ba234
+guid: d1e6e17fde84f4d8ca6e6fa9dd60f434
ScriptedImporter:
internalIDToNameTable: []
externalObjects: {}
diff --git a/Assets/Resources/UITk/Themes/Design System Files/UIElementsDesignSystemTemplate.uxml b/Assets/Resources/UITk/Themes/Design System Files/UIElementsDesignSystemTemplate.uxml
new file mode 100644
index 0000000..375c163
--- /dev/null
+++ b/Assets/Resources/UITk/Themes/Design System Files/UIElementsDesignSystemTemplate.uxml
@@ -0,0 +1,11 @@
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Assets/Resources/UITk/Themes/Design System Files/UIElementsDesignSystemTemplate.uxml.meta b/Assets/Resources/UITk/Themes/Design System Files/UIElementsDesignSystemTemplate.uxml.meta
new file mode 100644
index 0000000..77a66b0
--- /dev/null
+++ b/Assets/Resources/UITk/Themes/Design System Files/UIElementsDesignSystemTemplate.uxml.meta
@@ -0,0 +1,10 @@
+fileFormatVersion: 2
+guid: 1db949a81502f4c6e88a39409aefb357
+ScriptedImporter:
+ internalIDToNameTable: []
+ externalObjects: {}
+ serializedVersion: 2
+ userData:
+ assetBundleName:
+ assetBundleVariant:
+ script: {fileID: 13804, guid: 0000000000000000e000000000000000, type: 0}
diff --git a/Assets/Resources/UITk/Themes/GreenStyle/GreenStyle.Colors.uss b/Assets/Resources/UITk/Themes/GreenStyle/GreenStyle.Colors.uss
deleted file mode 100644
index ab03ef1..0000000
--- a/Assets/Resources/UITk/Themes/GreenStyle/GreenStyle.Colors.uss
+++ /dev/null
@@ -1,7 +0,0 @@
-.lsp-splash {
- background-image: url('project://database/Assets/UI/Splash-Screen.png?fileID=4602334432413793429&guid=364b68ded9ed04f07848b6c7de25fdad&type=3#Intro Screen_0');
-}
-
-.lsp-intro-view {
- background-image: url('project://database/Assets/UI/Background-Intro.png?fileID=7601968805574212021&guid=718087ba784b64abd9675b1452fc0095&type=3#Main Menu-1-Name Input_0');
-}
diff --git a/Assets/Resources/UITk/Themes/GreenStyle/GreenStyle.tss b/Assets/Resources/UITk/Themes/GreenStyle/GreenStyle.tss
deleted file mode 100644
index a220c7b..0000000
--- a/Assets/Resources/UITk/Themes/GreenStyle/GreenStyle.tss
+++ /dev/null
@@ -1,57 +0,0 @@
-/*@import url("/Assets/Resources/UITk/Themes/Common/CommonStyle.tss");
-@import url("GreenStyle.Colors.uss");*/
-@import url("unity-theme://default");
-
-:root {
- font-size: 64px;
- -unity-text-generator: advanced
-}
-
- :root {
- --lsp-row: row;
- --lsp-row-reverse: row-reverse;
- --lsp-left: left;
- --lsp-middle-left: middle-left;
- --lsp-right: right;
- --lsp-middle-right: middle-right;
-}
-
-:root.bold-text {
- -unity-font-style: bold;
-}
-
-:root.lsp-dir-rtl {
- --lsp-row: row-reverse;
- --lsp-row-reverse: row;
- --lsp-left: right;
- --lsp-middle-left: middle-right;
- --lsp-right: left;
- --lsp-middle-right: middle-left;
- -unity-text-align: right;
-}
-
-/* Dropdown */
-.unity-base-dropdown__container-outer {
- border-width: 10px;
- border-color: black;
- border-radius: 30px;
- margin-top: -10px;
-}
-
-.unity-base-dropdown__container-outer > .unity-scroll-view {
- border-radius: 20px;
- background-color: white;
-}
-
-.unity-base-dropdown__item {
-}
-
-.unity-base-dropdown__item:hover:enabled {
- background-color: #01C684;
-}
-
-.unity-base-dropdown__checkmark {
- margin: 30px;
- width: 50px;
- height: 50px;
-}
diff --git a/Assets/Resources/UITk/Themes/LetterSpellStyle.Common.Vars.uss b/Assets/Resources/UITk/Themes/LetterSpellStyle.Common.Vars.uss
new file mode 100644
index 0000000..60405af
--- /dev/null
+++ b/Assets/Resources/UITk/Themes/LetterSpellStyle.Common.Vars.uss
@@ -0,0 +1,123 @@
+@import url("Tokens/LetterSpellStyle.Tokens.Common.uss");
+
+:root {
+ font-size: var(--lsp-font-size-md);
+
+ /* BaseField */
+ --unity-metrics-base_field_label-min_width: var(--lsp-field-label-min-width);
+ --unity-metrics-base_field_label-margin: var(--lsp-spacing-md) var(--lsp-spacing-md);
+
+ /* Button */
+ --unity-metrics-button-border_width: var(--lsp-border-width-md);
+ --unity-metrics-button-border_radius: var(--lsp-border-radius-md);
+ --unity-metrics-button-margin: var(--lsp-spacing-sm) var(--lsp-spacing-sm);
+ --unity-metrics-button-padding: var(--lsp-spacing-md) var(--lsp-spacing-lg);
+
+ --unity-colors-button-background: var(--lsp-control-bg-color);
+ --unity-colors-button-border: var(--lsp-control-border-color);
+ --unity-colors-button-border-hover: var(--lsp-control-border-color);
+ --unity-colors-button-border-focus: var(--lsp-color-blue-600);
+ --unity-colors-button-background-hover: var(--lsp-control-bg-color-hover);
+ --unity-colors-button-background-pressed: var(--lsp-control-bg-color-pressed);
+ --unity-colors-button-background-checked: var(--lsp-control-bg-color-checked);
+
+ /* DropdownField */
+ --unity-metrics-dropdown_popup-border_width: var(--lsp-border-width-md);
+ --unity-metrics-dropdown_popup-border_radius: var(--lsp-border-radius-md);
+ --unity-metrics-dropdown_item_checkmark-width: var(--lsp-checkmark-size-sm);
+ --unity-metrics-dropdown_item_checkmark-height: var(--lsp-checkmark-size-sm);
+ --unity-metrics-dropdown_item_checkmark-margin: var(--lsp-spacing-md);
+
+ --unity-colors-dropdown_popup-border: var(--lsp-control-border-color);
+ --unity-colors-dropdown_popup-background: var(--lsp-secondary-color);
+ --unity-colors-dropdown_item-background-hover: var(--lsp-primary-color);
+
+ /* Input Field */
+ --unity-metrics-input_field-border_width: var(--lsp-border-width-md);
+ --unity-metrics-input_field-border_radius: var(--lsp-border-radius-md);
+ --unity-metrics-input_field-margin: var(--lsp-spacing-sm) var(--lsp-spacing-sm);
+ --unity-metrics-input_field-padding: var(--lsp-spacing-md) var(--lsp-spacing-lg);
+
+ --unity-colors-input_field-background: var(--lsp-input-bg-color);
+ --unity-colors-input_field-border: var(--lsp-input-border-color);
+ --unity-colors-input_field_placeholder-color: var(--lsp-input-placeholder-text-color);
+
+ /* PopupField */
+ --unity-metrics-popup_field-border_width: var(--lsp-border-width-md);
+ --unity-metrics-popup_field-border_radius: var(--lsp-border-radius-md);
+ --unity-metrics-popup_field-margin: var(--lsp-spacing-sm) var(--lsp-spacing-sm);
+ --unity-metrics-popup_field-padding: var(--lsp-spacing-md) var(--lsp-spacing-lg);
+ --unity-metrics-popup_field_arrow-width: var(--lsp-popup-field-arrow-width-md);
+ --unity-metrics-popup_field_arrow-height: var(--lsp-popup-field-arrow-width-md);
+ --unity-metrics-popup_field_arrow-margin: var(--lsp-spacing-sm) var(--lsp-spacing-md);
+
+ --unity-colors-popup_field-background: var(--lsp-control-bg-color);
+ --unity-colors-popup_field-border: var(--lsp-control-border-color);
+ --unity-colors-popup_field-border-hover: var(--lsp-control-border-color);
+ --unity-colors-popup_field-border-focus: var(--lsp-color-blue-600);
+ --unity-colors-popup_field-background-hover: var(--lsp-control-bg-color-hover);
+ --unity-colors-popup_field-background-pressed: var(--lsp-control-bg-color-checked);
+
+ /* Radio Button */
+ --unity-metrics-radio_button_checkmark_background-width: var(--lsp-checkmark-size-md);
+ --unity-metrics-radio_button_checkmark_background-border_width: var(--lsp-border-width-sm);
+ --unity-metrics-radio_button_checkmark-width: var(--lsp-checkmark-size-md);
+ --unity-metrics-toggle_checkmark-margin: var(--lsp-spacing-sm);
+ --unity-metrics-toggle_checkmark-border_width: var(--lsp-border-width-sm);
+ --unity-metrics-toggle_checkmark-border_radius: var(--lsp-border-radius-xs);
+
+ --unity-colors-radio_button_checkmark_background-background: var(--lsp-control-bg-color);
+ --unity-colors-radio_button_checkmark_background-background-hover: var(--lsp-control-bg-color-hover);
+ --unity-colors-radio_button_checkmark_background-border: var(--lsp-control-border-color);
+ --unity-colors-radio_button_checkmark-background: var(--lsp-primary-accent-color);
+ --unity-colors-radio_button_checkmark-background-hover: var(--lsp-primary-accent-color-hover);
+ --unity-colors-radio_button_checkmark-background-pressed: var(--lsp-primary-accent-color-checked);
+
+ /* Toggle */
+ --unity-metrics-toggle_checkmark-width: var(--lsp-checkmark-size-md);
+ --unity-metrics-toggle_checkmark-height: var(--lsp-checkmark-size-md);
+ --unity-metrics-toggle_checkmark-margin: var(--lsp-spacing-sm);
+ --unity-metrics-toggle_checkmark-border_width: var(--lsp-border-width-sm);
+ --unity-metrics-toggle_checkmark-border_radius: var(--lsp-border-radius-xs);
+
+ --unity-colors-toggle_checkmark-background: var(--lsp-control-bg-color);
+ --unity-colors-toggle_checkmark-background-hover: var(--lsp-control-bg-color-hover);
+ --unity-colors-toggle_checkmark-border: var(--lsp-control-border-color);
+ --unity-colors-toggle_checkmark-border-focus: var(--lsp-control-border-color);
+ --unity-colors-toggle_checkmark-text: var(--lsp-primary-accent-color);
+
+ /* Slider */
+ --unity-metrics-slider_groove-height: var(--lsp-slider-groove-height-md);
+ --unity-metrics-slider_groove-border_radius: var(--lsp-border-radius-xs);
+ --unity-metrics-slider_thumb-width: var(--lsp-slider-thumb-width-md);
+ --unity-metrics-slider_thumb-height: var(--lsp-slider-thumb-height-md);
+ --unity-metrics-slider_thumb-border_width: var(--lsp-border-width-sm);
+ --unity-metrics-slider_thumb-border_radius: var(--lsp-border-radius-xs);
+
+ --unity-colors-slider_groove-background: var(--lsp-control-border-color);
+ --unity-colors-slider_groove-background-hover: var(--lsp-control-border-color-hover);
+ --unity-colors-slider_groove-border: var(--lsp-control-border-color);
+ --unity-colors-slider_groove-border-hover: var(--lsp-control-border-color-hover);
+ --unity-colors-slider_thumb-background: var(--lsp-primary-accent-color);
+ --unity-colors-slider_thumb-background-hover: var(--lsp-primary-accent-color-hover);
+ --unity-colors-slider_thumb-border: var(--lsp-control-border-color);
+ --unity-colors-slider_thumb-border-focus: var(--lsp-control-border-color-focus);
+
+ /* Window */
+ --unity-metrics-window-border_width: var(--lsp-border-width-md);
+ --unity-metrics-window-border_radius: var(--lsp-border-radius-md);
+
+ --unity-colors-window-background: var(--lsp-color-white);
+ --unity-colors-window-border: var(--lsp-color-black);
+
+ /***************************************/
+ /* LetterSpellStyle Specific Styles */
+ /***************************************/
+ --lsp-metrics-letter_card_view_item-border_width: var(--lsp-border-width-md);
+ --lsp-metrics-letter_card_view_item-border_radius: var(--lsp-border-radius-md);
+
+ --lsp-colors-letter_card_view_item-background: var(--lsp-card-bg-color);
+ --lsp-colors-letter_card_view_item-background-selected: var(--lsp-card-bg-color-selected);
+ --lsp-colors-letter_card_view_item-border: var(--lsp-card-border-color);
+ --lsp-colors-letter_card_view_item-border-selected: var(--lsp-card-border-color-selected);
+}
\ No newline at end of file
diff --git a/Assets/Resources/UITk/Themes/Common/CommonStyle.Rules.uss.meta b/Assets/Resources/UITk/Themes/LetterSpellStyle.Common.Vars.uss.meta
similarity index 79%
rename from Assets/Resources/UITk/Themes/Common/CommonStyle.Rules.uss.meta
rename to Assets/Resources/UITk/Themes/LetterSpellStyle.Common.Vars.uss.meta
index 7491ab6..7dcc17a 100644
--- a/Assets/Resources/UITk/Themes/Common/CommonStyle.Rules.uss.meta
+++ b/Assets/Resources/UITk/Themes/LetterSpellStyle.Common.Vars.uss.meta
@@ -1,5 +1,5 @@
fileFormatVersion: 2
-guid: c83b18b034f264b94a16350f6341e65d
+guid: 16e4a57eb810043538d970ce7d40fe1e
ScriptedImporter:
internalIDToNameTable: []
externalObjects: {}
@@ -9,3 +9,4 @@ ScriptedImporter:
assetBundleVariant:
script: {fileID: 12385, guid: 0000000000000000e000000000000000, type: 0}
disableValidation: 0
+ unsupportedSelectorAction: 0
diff --git a/Assets/Resources/UITk/Themes/LetterSpellStyle.Common.uss b/Assets/Resources/UITk/Themes/LetterSpellStyle.Common.uss
new file mode 100644
index 0000000..72356a8
--- /dev/null
+++ b/Assets/Resources/UITk/Themes/LetterSpellStyle.Common.uss
@@ -0,0 +1,425 @@
+@import url("unity-theme://default");
+@import url("LetterSpellStyle.Common.Vars.uss");
+
+:root {
+ font-size: var(--lsp-font-size-md);
+ color: var(--lsp-primary-text-color);
+ -unity-text-generator: advanced;
+}
+
+/* BaseField */
+.unity-base-field {
+ margin: var(--unity-metrics-input_field-margin);
+}
+
+.unity-base-field__label {
+ min-width: var(--unity-metrics-base_field_label-min_width);
+ -unity-text-align: middle-left;
+ margin: var(--unity-metrics-base_field_label-margin);
+}
+
+/* Button */
+.unity-button {
+ margin: var(--unity-metrics-button-margin);
+ padding: var(--unity-metrics-button-padding);
+ background-color: var(--unity-colors-button-background);
+ border-color: var(--unity-colors-button-border);
+ border-width: var(--unity-metrics-button-border_width);
+ border-radius: var(--unity-metrics-button-border_radius);
+ -unity-font-definition: var(--lsp-font-bold);
+}
+
+.unity-button:focus:enabled {
+ border-color: var(--unity-colors-button-border-focus);
+}
+
+.unity-button:hover:enabled,
+.unity-button:hover:checked:enabled {
+ background-color: var(--unity-colors-button-background-hover);
+ border-color: var(--unity-colors-button-border-hover);
+}
+
+.unity-button:hover:active:enabled {
+ background-color: var(--unity-colors-button-background-pressed);
+}
+
+.unity-button:checked:enabled {
+ background-color: var(--unity-colors-button-background-checked);
+}
+
+/* DropdownField and EnumField */
+.unity-base-dropdown__checkmark {
+ width: var(--unity-metrics-dropdown_item_checkmark-width);
+ height: var(--unity-metrics-dropdown_item_checkmark-height);
+ margin: var(--unity-metrics-dropdown_item_checkmark-margin);
+}
+
+.unity-base-dropdown__container-outer {
+ border-width: var(--unity-metrics-dropdown_popup-border_width);
+ border-color: var(--unity-colors-dropdown_popup-border);
+ border-radius: var(--unity-metrics-dropdown_popup-border_radius);
+ overflow: hidden;
+}
+
+.unity-base-dropdown__container-outer > .unity-scroll-view {
+ background-color: var(--unity-colors-dropdown_popup-background);
+}
+
+.unity-base-dropdown__item:hover:enabled {
+ background-color: var(--unity-colors-dropdown_item-background-hover);
+}
+
+.unity-base-dropdown__item > .unity-base-dropdown__item-content > .unity-base-dropdown__label {
+ margin-left: var(--lsp-spacing-lg);
+}
+
+/* PopupField */
+.unity-base-popup-field__input {
+ padding: var(--unity-metrics-popup_field-padding);
+ background-color: var(--unity-colors-popup_field-background);
+ border-color: var(--unity-colors-popup_field-border);
+ border-width: var(--unity-metrics-popup_field-border_width);
+ border-radius: var(--unity-metrics-popup_field-border_radius);
+}
+
+.unity-base-field:hover:enabled > .unity-base-popup-field__input {
+ background-color: var(--unity-colors-popup_field-background-hover);
+ border-color: var(--unity-colors-popup_field-border);
+}
+
+.unity-base-field:active:enabled > .unity-base-popup-field__input {
+ background-color: var(--unity-colors-popup_field-background-pressed);
+ border-color: var(--unity-colors-popup_field-border);
+}
+
+.unity-enum-field__arrow,
+.unity-base-popup-field__arrow {
+ width: var(--unity-metrics-popup_field_arrow-width);
+ height: var(--unity-metrics-popup_field_arrow-height);
+ margin: var(--unity-metrics-popup_field_arrow-margin);
+ background-image: var(--unity-icons-dropdown);
+}
+
+/* RadioButton */
+.unity-radio-button .unity-radio-button__checkmark-background {
+ border-width: var(--unity-metrics-radio_button_checkmark_background-border_width);
+ border-color: var(--unity-colors-radio_button_checkmark_background-border);
+ background-color: var(--unity-colors-radio_button_checkmark_background-background);
+ padding: 0;
+ width: var(--unity-metrics-radio_button_checkmark-width);
+ height: var(--unity-metrics-radio_button_checkmark-width);
+ border-radius: 50%;
+}
+
+.unity-radio-button > .unity-radio-button__input:hover:enabled > .unity-radio-button__checkmark-background {
+ background-color: var(--unity-colors-radio_button_checkmark_background-background-hover);
+ border-color: var(--unity-colors-radio_button_checkmark_background-border);
+}
+
+.unity-radio-button > .unity-radio-button__input > .unity-radio-button__checkmark-background > .unity-radio-button__checkmark {
+ width: 100%;
+ height: 100%;
+ border-radius: 50%;
+ background-color: var(--unity-colors-radio_button_checkmark-background);
+}
+
+.unity-radio-button > .unity-radio-button__input:hover:enabled > .unity-radio-button__checkmark-background > .unity-radio-button__checkmark {
+ background-color: var(--unity-colors-radio_button_checkmark-background-hover);
+}
+
+.unity-radio-button:active > .unity-radio-button__input > .unity-radio-button__checkmark-background > .unity-radio-button__checkmark {
+ background-color: var(--unity-colors-radio_button_checkmark-background-pressed);
+}
+
+/* Slider */
+.unity-base-slider {
+}
+
+.unity-base-slider .unity-base-slider__tracker {
+ background-color: var(--unity-colors-slider_groove-background);
+ border-width: 0;
+ border-radius: var(--unity-metrics-slider_groove-border_radius);
+}
+
+.unity-base-slider .unity-base-slider__tracker:hover:enabled {
+ background-color: var(--unity-colors-slider_groove-background-hover);
+}
+
+.unity-base-slider--vertical .unity-base-slider__tracker {
+ margin-left: 0;
+ left: 50%;
+ translate: -50% 0;
+ width: var(--unity-metrics-slider_groove-height);
+}
+
+.unity-base-slider--horizontal .unity-base-slider__tracker {
+ margin: 0;
+ top: 50%;
+ translate: 0 -50%;
+ height: var(--unity-metrics-slider_groove-height);
+}
+
+.unity-base-slider .unity-base-slider__dragger {
+ border-width: var(--unity-metrics-slider_thumb-border_width);
+ border-color: var(--unity-colors-slider_thumb-border);
+ border-radius: var(--unity-metrics-slider_thumb-border_radius);
+ background-color: var(--unity-colors-slider_thumb-background);
+}
+
+.unity-base-slider .unity-base-slider__dragger:hover:enabled {
+ background-color: var(--unity-colors-slider_thumb-background-hover);
+ border-color: var(--unity-colors-slider_thumb-border);
+}
+
+.unity-base-slider--horizontal .unity-base-slider__dragger {
+ top: 50%;
+ width: var(--unity-metrics-slider_thumb-width);
+ height: var(--unity-metrics-slider_thumb-height);
+ margin: 0;
+ margin-top: -33px; /* 50% of height*/
+}
+
+.unity-base-slider--vertical .unity-base-slider__dragger {
+ left: 50%;
+ height: var(--unity-metrics-slider_thumb-width);
+ width: var(--unity-metrics-slider_thumb-height);
+ margin: 0;
+ margin-left: -33px; /* 50% of height*/
+}
+
+/* TextField */
+.unity-base-text-field__input {
+ padding: var(--unity-metrics-input_field-padding);
+ background-color: var(--unity-colors-input_field-background);
+ border-color: var(--unity-colors-input_field-border);
+ border-width: var(--unity-metrics-input_field-border_width);
+ border-radius: var(--unity-metrics-input_field-border_radius);
+}
+
+.unity-base-text-field__input--placeholder {
+ color: var(--unity-colors-input_field_placeholder-color);
+}
+
+/* Toggle */
+.unity-toggle>.unity-toggle__input>.unity-toggle__checkmark {
+ background-color: var(--unity-colors-toggle_checkmark-background);
+ border-color: var(--unity-colors-toggle_checkmark-border);
+ border-width: var(--unity-metrics-toggle_checkmark-border_width);
+ border-radius: var(--unity-metrics-toggle_checkmark-border_radius);
+ -unity-background-image-tint-color: var(--unity-colors-toggle_checkmark-text);
+ width: var( --unity-metrics-toggle_checkmark-width);
+ height: var(--unity-metrics-toggle_checkmark-height);
+ margin-right: var(--unity-metrics-toggle_checkmark-margin);
+}
+
+.unity-toggle:hover > .unity-toggle__input > .unity-toggle__checkmark {
+ background-color: var(--unity-colors-toggle_checkmark-background-hover);
+}
+
+.unity-toggle>.unity-toggle__input:checked>.unity-toggle__checkmark {
+ border-color: var(--unity-colors-toggle_checkmark-border);
+}
+
+.unity-toggle:focus:enabled>.unity-toggle__input>.unity-toggle__checkmark {
+ border-color: var(--unity-colors-toggle_checkmark-border-focus);
+}
+
+/************************************************/
+/* LetterSpellStyle Specific Styles */
+/************************************************/
+.lsp-background {
+ position: absolute;
+ left: 0;
+ right: 0;
+ top: 0;
+ bottom: 0;
+ background-color: var(--lsp-primary-color);
+}
+
+/* Button */
+.unity-button.lsp-primary-accent-button {
+ background-color: var(--lsp-primary-accent-color);
+ color: var(--lsp-primary-accent-text-color);
+}
+
+.unity-button.lsp-primary-accent-button:hover:enabled {
+ background-color: var(--lsp-primary-accent-color-hover);
+}
+
+.unity-button.lsp-primary-accent-button:active:enabled {
+ background-color: var(--lsp-primary-accent-color-checked);
+}
+
+.unity-button.lsp-secondary-accent-button {
+ background-color: var(--lsp-secondary-accent-color);
+ border-color: var(--lsp-secondary-accent-border-color);
+ color: var(--lsp-secondary-accent-text-color);
+}
+
+.unity-button.lsp-secondary-accent-button:hover:enabled {
+ background-color: var(--lsp-secondary-accent-color-hover);
+ border-color: var(--lsp-secondary-accent-border-color);
+}
+
+.unity-button.lsp-secondary-accent-button:active:enabled {
+ background-color: var(--lsp-secondary-accent-color-checked);
+ border-color: var(--lsp-secondary-accent-border-color);
+}
+
+.unity-button.lsp-secondary-accent-button:focus {
+ border-color: var(--lsp-secondary-accent-border-color);
+}
+
+.unity-button.lsp-third-accent-button {
+ background-color: var(--lsp-third-accent-color);
+ border-color: var(--lsp-third-accent-border-color);
+ color: var(--lsp-third-accent-text-color);
+}
+
+.unity-button.lsp-third-accent-button:hover:enabled {
+ background-color: var(--lsp-third-accent-color-hover);
+ border-color: var(--lsp-third-accent-border-color);
+}
+
+.unity-button.lsp-third-accent-button:active:enabled {
+ background-color: var(--lsp-third-accent-color-checked);
+ border-color: var(--lsp-third-accent-border-color);
+}
+
+.unity-button.lsp-third-accent-button:focus {
+ border-color: var(--lsp-third-accent-border-color);
+}
+
+.unity-button.lsp-button-xl {
+ padding: var(--lsp-spacing-xxl) var(--lsp-spacing-xl);
+ margin: var(--lsp-spacing-md) var(--lsp-spacing-lg);
+}
+
+/* ButtonStrip */
+.lsp-button-strip-field {
+ --unity-colors-button-background: var(--lsp-primary-accent-color);
+ --unity-colors-button-background-hover: var(--lsp-primary-accent-color-hover);
+ --unity-colors-button-background-pressed: var(--lsp-primary-accent-color-pressed);
+ --unity-colors-button-background-checked: var(--lsp-primary-accent-color-checked);
+}
+
+.lsp-button-strip-field__button-container {
+ color: var(--lsp-primary-accent-text-color);
+ flex-direction: row;
+}
+
+.lsp-button-strip-field__button {
+ margin-left: 0;
+ margin-right: 0;
+ margin-top: 0;
+ margin-bottom: 0;
+}
+
+.lsp-button-strip-field__button--left {
+ margin-right: 0;
+ border-right-width: var(--lsp-border-width-md-half);
+ border-top-right-radius: 0;
+ border-bottom-right-radius: 0;
+}
+
+.lsp-button-strip-field__button--right {
+ border-top-left-radius: 0;
+ border-bottom-left-radius: 0;
+ border-left-width: 5px;
+ margin-left: 0;
+}
+
+/*.lsp-button-strip-field__button:checked {
+ background-color: rgb(116, 45, 243);
+}
+*/
+/* Card */
+.lsp-letter-card {
+}
+
+.lsp-letter-card-view > .lsp-letter-card-view__item {
+ position: absolute;
+ transition-property: rotate;
+ transition-duration: 400ms;
+ background-color: var(--lsp-colors-letter_card_view_item-background);
+ border-width: var(--lsp-metrics-letter_card_view_item-border_width);
+ border-radius: var(--lsp-metrics-letter_card_view_item-border_radius);
+ align-items: center;
+ justify-content: center;
+ -unity-font-definition: url("project://database/Assets/UI/Fonts/Inter-SemiBold.ttf?fileID=12800000&guid=3b458681b475c476ea29f3244c5c85da&type=3#Inter-SemiBold");
+}
+
+.lsp-letter-card-view > .lsp-letter-card-view__item--selected {
+ background-color: var( --lsp-colors-letter_card_view_item-background-selected);
+ border-color: var(--lsp-colors-letter_card_view_item-border-selected);
+ rotate: -15deg;
+}
+
+.lsp-letter-card-view > .lsp-letter-card-view__item--dragged-left {
+ rotate: 20deg;
+}
+
+.lsp-letter-card-view > .lsp-letter-card-view__item--dragged-right {
+ rotate: -20deg;
+}
+
+.lsp-letter-card-view > .lsp-letter-card-view__item--animated {
+ transition-property: left, top, margin-top, rotate;
+ transition-duration: 0.4s, 0.4s, 0.4s, 0.4s;
+ transition-timing-function: ease, ease, ease, ease-out;
+}
+
+/* Title text */
+.lsp-h1 {
+ -unity-font-definition: var(--lsp-font-bold);
+ margin-top: var(--lsp-spacing-md);
+ margin-bottom: var(--lsp-spacing-md);
+ color: var(--lsp-secondary-text-color);
+}
+
+.lsp-h2 {
+ margin-top: var(--lsp-spacing-lg);
+ margin-bottom: var(--lsp-spacing-md);
+ -unity-font-definition: var(--lsp-font-bold);
+}
+
+/* Logo */
+.lsp-logo {
+ position: absolute;
+ background-image: var(--lsp-images-logo);
+ width: var(--lsp-images-logo-w);
+ height: var(--lsp-images-logo-h);
+ top: 58px;
+ left: 52px;
+}
+
+/* Pause */
+.lsp-pause-icon {
+ background-image: var(--lsp-icons-pause);
+ width: var(--lsp-icons-pause-w);
+ height: var(--lsp-icons-pause-h);
+ -unity-background-scale-mode: scale-to-fit;
+}
+
+/* Pill */
+.lsp-pill {
+ background-color: var(--lsp-secondary-color);
+ border-radius: var(--lsp-border-radius-xl);
+ padding: var(--lsp-spacing-xs) var(--lsp-spacing-md);
+ -unity-font-definition: var(--lsp-font-bold);
+ flex-direction: row;
+ justify-content: center;
+ align-items: center;
+}
+
+/* Popup */
+.lsp-popup {
+ background-color: var(--unity-colors-window-background);
+ padding-top: var(--lsp-spacing-lg);
+ padding-right: var(--lsp-spacing-xl);
+ padding-bottom: var(--lsp-spacing-sm);
+ padding-left: var(--lsp-spacing-xl);
+ border-color: var(--unity-colors-window-border);
+ border-width: var(--unity-metrics-window-border_width);
+ border-radius: var(--unity-metrics-window-border_radius);
+}
\ No newline at end of file
diff --git a/Assets/Resources/UITk/Themes/GreenStyle/GreenStyle.Colors.uss.meta b/Assets/Resources/UITk/Themes/LetterSpellStyle.Common.uss.meta
similarity index 79%
rename from Assets/Resources/UITk/Themes/GreenStyle/GreenStyle.Colors.uss.meta
rename to Assets/Resources/UITk/Themes/LetterSpellStyle.Common.uss.meta
index 6403700..e79815e 100644
--- a/Assets/Resources/UITk/Themes/GreenStyle/GreenStyle.Colors.uss.meta
+++ b/Assets/Resources/UITk/Themes/LetterSpellStyle.Common.uss.meta
@@ -1,5 +1,5 @@
fileFormatVersion: 2
-guid: a91a3cd95022b4feda8886719867bb42
+guid: aa285b98ae59f4450a2b1e64d7d303c6
ScriptedImporter:
internalIDToNameTable: []
externalObjects: {}
@@ -9,3 +9,4 @@ ScriptedImporter:
assetBundleVariant:
script: {fileID: 12385, guid: 0000000000000000e000000000000000, type: 0}
disableValidation: 0
+ unsupportedSelectorAction: 0
diff --git a/Assets/Resources/UITk/Themes/LetterSpellStyle.Green.tss b/Assets/Resources/UITk/Themes/LetterSpellStyle.Green.tss
new file mode 100644
index 0000000..7a9fadd
--- /dev/null
+++ b/Assets/Resources/UITk/Themes/LetterSpellStyle.Green.tss
@@ -0,0 +1,41 @@
+@import url("Tokens/LetterSpellStyle.Tokens.Green.uss");
+@import url("LetterSpellStyle.Common.uss");
+
+:root {
+ --lsp-primary-color: var(--lsp-color-green);
+ --lsp-secondary-color: var(--lsp-color-white);
+ --lsp-primary-text-color: var(--lsp-color-black);
+ --lsp-secondary-text-color: var(--lsp-color-white);
+ --lsp-primary-accent-color: var(--lsp-color-purple);
+ --lsp-primary-accent-color-hover: var(--lsp-color-purple-lighter-130);
+ --lsp-primary-accent-color-checked: var(--lsp-color-purple-darker-120);
+ --lsp-primary-accent-text-color: var(--lsp-color-white);
+ --lsp-secondary-accent-color: var(--lsp-color-yellow);
+ --lsp-secondary-accent-color-hover: var(--lsp-color-yellow-lighter-110);
+ --lsp-secondary-accent-color-checked: var(--lsp-color-yellow-darker-130);
+ --lsp-secondary-accent-border-color: var(--lsp-color-yellow-light);
+ --lsp-secondary-accent-text-color: var(--lsp-color-white);
+ --lsp-third-accent-color: var(--lsp-color-blue);
+ --lsp-third-accent-color-hover: var(--lsp-color-blue-lighter-110);
+ --lsp-third-accent-color-checked: var(--lsp-color-blue-darker-120);
+ --lsp-third-accent-border-color: var(--lsp-color-blue-light);
+ --lsp-third-accent-text-color: var(--lsp-color-white);
+
+ --lsp-control-bg-color: var(--lsp-color-white);
+ --lsp-control-bg-color-hover: var(--lsp-color-yellow);
+ --lsp-control-bg-color-pressed: var(--lsp-color-yellow-darker-130);
+ --lsp-control-bg-color-checked: var(--lsp-color-yellow-darker-120);
+ --lsp-control-border-color: var(--lsp-color-black);
+ --lsp-control-border-color-hover: var(--lsp-color-yellow);
+ --lsp-control-border-color-focus: var(--lsp-color-blue-600);
+
+ --lsp-input-bg-color: var(--lsp-color-white);
+ --lsp-input-bg-color-hover: var(--lsp-color-yellow);
+ --lsp-input-bg-color-checked: var(--lsp-color-yellow-darker-130);
+ --lsp-input-border-color: var(--lsp-color-black);
+
+ --lsp-card-bg-color: var(--lsp-color-yellow-light);
+ --lsp-card-bg-color-selected: var(--lsp-color-yellow);
+ --lsp-card-border-color: var(--lsp-color-yellow-light);
+ --lsp-card-border-color-selected: var(--lsp-color-black);
+}
diff --git a/Assets/Resources/UITk/Themes/Common/CommonStyle.tss.meta b/Assets/Resources/UITk/Themes/LetterSpellStyle.Green.tss.meta
similarity index 79%
rename from Assets/Resources/UITk/Themes/Common/CommonStyle.tss.meta
rename to Assets/Resources/UITk/Themes/LetterSpellStyle.Green.tss.meta
index 35504a9..32b9a83 100644
--- a/Assets/Resources/UITk/Themes/Common/CommonStyle.tss.meta
+++ b/Assets/Resources/UITk/Themes/LetterSpellStyle.Green.tss.meta
@@ -1,5 +1,5 @@
fileFormatVersion: 2
-guid: 0485cc741575d4616b02a941a153257c
+guid: d86247bbccfab4ab78d250562c950f18
ScriptedImporter:
internalIDToNameTable: []
externalObjects: {}
@@ -9,3 +9,4 @@ ScriptedImporter:
assetBundleVariant:
script: {fileID: 12388, guid: 0000000000000000e000000000000000, type: 0}
disableValidation: 0
+ unsupportedSelectorAction: 0
diff --git a/Assets/Resources/UITk/Themes/LetterSpellTheme.uss b/Assets/Resources/UITk/Themes/LetterSpellTheme.uss
deleted file mode 100644
index ebfc90a..0000000
--- a/Assets/Resources/UITk/Themes/LetterSpellTheme.uss
+++ /dev/null
@@ -1,630 +0,0 @@
-.unity-button {
- padding-top: 30px;
- padding-right: 70px;
- padding-bottom: 30px;
- padding-left: 70px;
- border-top-left-radius: 30px;
- border-top-right-radius: 30px;
- border-bottom-right-radius: 30px;
- border-bottom-left-radius: 30px;
- border-top-width: 10px;
- border-right-width: 10px;
- border-bottom-width: 10px;
- border-left-width: 10px;
- border-left-color: rgb(0, 0, 0);
- border-right-color: rgb(0, 0, 0);
- border-top-color: rgb(0, 0, 0);
- border-bottom-color: rgb(0, 0, 0);
- margin-top: 30px;
- background-color: rgb(255, 255, 255);
- margin-bottom: 30px;
- margin-right: 30px;
- margin-left: 30px;
- -unity-font-definition: url("project://database/Assets/UI/Fonts/Inter-SemiBold.ttf?fileID=12800000&guid=3b458681b475c476ea29f3244c5c85da&type=3#Inter-SemiBold");
-}
-
-.unity-button:hover {
- background-color: rgb(220, 180, 0);
-}
-
-.unity-label {
-}
-
-.unity-base-text-field__input {
- border-top-width: 10px;
- border-right-width: 10px;
- border-bottom-width: 10px;
- border-left-width: 10px;
- border-left-color: rgb(0, 0, 0);
- border-right-color: rgb(0, 0, 0);
- border-top-color: rgb(0, 0, 0);
- border-bottom-color: rgb(0, 0, 0);
- border-top-left-radius: 30px;
- border-top-right-radius: 30px;
- border-bottom-right-radius: 30px;
- border-bottom-left-radius: 30px;
- background-color: rgb(255, 255, 255);
- padding-top: 30px;
- padding-bottom: 30px;
- padding-right: 70px;
- padding-left: 70px;
-}
-
-.unity-base-text-field {
- margin-top: 30px;
- margin-right: 4px;
- margin-bottom: 30px;
- margin-left: 4px;
-}
-
-#easyButton {
- background-color: rgb(255, 190, 0);
- border-left-color: rgb(255, 251, 232);
- border-right-color: rgb(255, 251, 232);
- border-top-color: rgb(255, 251, 232);
- border-bottom-color: rgb(255, 251, 232);
-}
-
-#easyButton:hover {
- background-color: rgb(250, 201, 55);
-}
-
-#easyButton:active {
- background-color: rgb(195, 147, 8);
-}
-
-#hardButton {
- background-color: rgb(1, 168, 255);
- border-left-color: rgb(114, 207, 255);
- border-right-color: rgb(114, 207, 255);
- border-top-color: rgb(114, 207, 255);
- border-bottom-color: rgb(114, 207, 255);
-}
-
-#hardButton:hover {
- background-color: rgb(46, 180, 250);
-}
-
-#hardButton:active {
- background-color: rgb(5, 131, 197);
-}
-
-.choice-button {
- padding-top: 140px;
- padding-right: 100px;
- padding-bottom: 140px;
- padding-left: 100px;
- margin-top: 30px;
- margin-right: 70px;
- margin-bottom: 30px;
- margin-left: 70px;
- border-top-left-radius: 35px;
- border-top-right-radius: 35px;
- border-bottom-right-radius: 35px;
- border-bottom-left-radius: 35px;
-}
-
-#nextWordButton {
-}
-
-.lsp-letter-card {
- transition-property: rotate;
- transition-duration: 400ms;
- background-color: rgb(255, 251, 232);
- border-top-width: 10px;
- border-right-width: 10px;
- border-bottom-width: 10px;
- border-left-width: 10px;
- width: 208px;
- height: 208px;
- border-top-left-radius: 30px;
- border-top-right-radius: 30px;
- border-bottom-right-radius: 30px;
- border-bottom-left-radius: 30px;
- align-items: center;
- justify-content: center;
- -unity-font-definition: url("project://database/Assets/UI/Fonts/Inter-SemiBold.ttf?fileID=12800000&guid=3b458681b475c476ea29f3244c5c85da&type=3#Inter-SemiBold");
-}
-
-.lsp-letter-card.selected {
- margin-top: 0;
- background-color: rgb(255, 190, 0);
- border-left-color: rgb(0, 0, 0);
- border-right-color: rgb(0, 0, 0);
- border-top-color: rgb(0, 0, 0);
- border-bottom-color: rgb(0, 0, 0);
- rotate: -15deg;
-}
-
-.lsp-letter-card__button-container {
- position: absolute;
- top: 100%;
- padding: 5px;
- display: none;
- flex-direction: row;
- justify-content: center;
- align-items: center;
- background-color: rgb(209, 253, 236);
- border-radius: 12px;
- border-top-left-radius: 0;
- border-top-right-radius: 0;
-}
-
-.lsp-letter-card.selected .lsp-letter-card__button-container {
- display: flex;
-}
-
-.lsp-letter-card__button {
- margin: 0;
- padding: 6px;
- -unity-font-definition: url("project://database/Assets/UI/Fonts/Inter-SemiBold.ttf?fileID=12800000&guid=3b458681b475c476ea29f3244c5c85da&type=3#Inter-SemiBold");
-}
-
-.lsp-letter-card__button--first {
- border-top-right-radius: 0;
- border-bottom-right-radius: 0;
- border-right-width: 2px;
-}
-
-.lsp-letter-card__button--mid {
- border-radius: 0;
- border-left-width: 2px;
- border-right-width: 2px;
-}
-
-.lsp-letter-card__button--last {
- border-top-left-radius: 0;
- border-bottom-left-radius: 0;
- border-left-width: 2px;
-}
-
-#cancelMoveButton {
- margin-left: 4px;
- background-color: rgb(243, 33, 33);
- color: white;
-}
-
-.lsp-card-view-item.animated {
- transition-property: left, top, margin-top, rotate;
- transition-duration: 0.4s, 0.4s, 0.4s, 0.4s;
- transition-timing-function: ease, ease, ease, ease-out;
-}
-
-.lsp-insertion-placeholder {
-}
-
-.lsp-letter-card.dragged {
- rotate: -20deg;
- border-left-color: rgb(0, 0, 0);
- border-right-color: rgb(0, 0, 0);
- border-top-color: rgb(0, 0, 0);
- border-bottom-color: rgb(0, 0, 0);
- background-color: rgb(214, 167, 49);
-}
-
-.lsp-letter-card.dragged.dragging--left {
- rotate: 20deg;
-}
-
-.lsp-letter-card.dragged.dragging--right {
- rotate: -20deg;
-}
-
-#settingsView {
- padding-top: 60px;
- padding-right: 70px;
- padding-bottom: 4px;
- padding-left: 70px;
-}
-
-.unity-label,
-.unity-base-field__label {
- -unity-text-align: var(--lsp-middle-left);
-}
-
-.unity-base-field__label {
- min-width: 680px;
-}
-
-.unity-radio-button-group__container {
- flex-grow: 1;
-}
-
-.unity-radio-button .unity-base-field__label {
- min-width: 0;
-}
-
-.unity-base-field__label {
- margin-right: 30px;
-}
-
-.settings-header-label {
- margin-top: 70px;
- -unity-font-definition: url("project://database/Assets/UI/Fonts/Inter-SemiBold.ttf?fileID=12800000&guid=3b458681b475c476ea29f3244c5c85da&type=3#Inter-SemiBold");
- margin-bottom: 30px;
-}
-
-.unity-radio-button__checkmark-background {
- border-top-width: 6px;
- border-right-width: 6px;
- border-bottom-width: 6px;
- border-left-width: 6px;
- border-left-color: rgb(0, 0, 0);
- border-right-color: rgb(0, 0, 0);
- border-top-color: rgb(0, 0, 0);
- border-bottom-color: rgb(0, 0, 0);
- background-color: rgba(0, 0, 0, 0);
- padding-top: 0;
- padding-right: 0;
- padding-bottom: 0;
- padding-left: 0;
- width: 50px;
- height: 50px;
- border-top-left-radius: 25px;
- border-top-right-radius: 25px;
- border-bottom-right-radius: 25px;
- border-bottom-left-radius: 25px;
-}
-
-.unity-radio-button__checkmark {
- width: 39px;
- height: 39.5px;
- border-top-left-radius: 20px;
- border-top-right-radius: 20px;
- border-bottom-right-radius: 20px;
- border-bottom-left-radius: 20px;
- background-color: rgb(161, 116, 244);
-}
-
-.unity-toggle__input {
- flex-direction: var(--lsp-row);
-}
-.unity-toggle__checkmark {
- background-color: rgba(0, 0, 0, 0);
- border-left-color: rgb(0, 0, 0);
- border-right-color: rgb(0, 0, 0);
- border-top-color: rgb(0, 0, 0);
- border-bottom-color: rgb(0, 0, 0);
- border-top-width: 6px;
- border-right-width: 6px;
- border-bottom-width: 6px;
- border-left-width: 6px;
- border-top-left-radius: 7px;
- border-top-right-radius: 7px;
- border-bottom-right-radius: 7px;
- border-bottom-left-radius: 7px;
- -unity-background-image-tint-color: rgb(161, 116, 244);
- width: 50px;
- height: 50px;
- margin-right: 30px;
- margin-left: 30px;
-}
-
-.unity-base-slider__tracker {
- background-color: rgb(0, 0, 0);
- height: 10px;
- border-top-width: 0;
- border-right-width: 0;
- border-bottom-width: 0;
- border-left-width: 0;
- border-top-left-radius: 5px;
- border-top-right-radius: 5px;
- border-bottom-right-radius: 5px;
- border-bottom-left-radius: 5px;
-}
-
-.unity-base-slider__dragger {
- background-color: rgb(161, 116, 244);
- border-top-width: 6px;
- border-right-width: 6px;
- border-bottom-width: 6px;
- border-left-width: 6px;
- border-left-color: rgb(0, 0, 0);
- border-right-color: rgb(0, 0, 0);
- border-top-color: rgb(0, 0, 0);
- border-bottom-color: rgb(0, 0, 0);
- border-top-left-radius: 10px;
- border-top-right-radius: 10px;
- border-bottom-right-radius: 10px;
- border-bottom-left-radius: 10px;
- width: 40px;
- height: 66px;
- margin-top: -33px;
-}
-
-.unity-base-popup-field__input {
- background-color: rgb(255, 255, 255);
- border-left-color: rgb(0, 0, 0);
- border-right-color: rgb(0, 0, 0);
- border-top-color: rgb(0, 0, 0);
- border-bottom-color: rgb(0, 0, 0);
- border-top-width: 10px;
- border-right-width: 10px;
- border-bottom-width: 10px;
- border-left-width: 10px;
- border-top-left-radius: 30px;
- border-top-right-radius: 30px;
- border-bottom-right-radius: 30px;
- border-bottom-left-radius: 30px;
- padding-top: 30px;
- padding-bottom: 30px;
- flex-direction: var(--lsp-row);
-}
-
-.unity-base-popup-field__text {
- -unity-text-align: var(--lsp-middle-left);
-}
-
-.unity-base-text-field__input--placeholder {
- color: rgb(164, 164, 164);
-}
-
-.purple {
- background-color: rgb(161, 116, 243);
- color: rgb(255, 255, 255);
-}
-
-.lsp-popup {
- background-color: rgb(255, 255, 255);
- padding-top: 70px;
- padding-right: 100px;
- padding-bottom: 20px;
- padding-left: 100px;
- border-left-color: rgb(0, 0, 0);
- border-right-color: rgb(0, 0, 0);
- border-top-color: rgb(0, 0, 0);
- border-bottom-color: rgb(0, 0, 0);
- border-top-width: 10px;
- border-right-width: 10px;
- border-bottom-width: 10px;
- border-left-width: 10px;
- border-top-left-radius: 30px;
- border-top-right-radius: 30px;
- border-bottom-right-radius: 30px;
- border-bottom-left-radius: 30px;
-}
-
-.lsp-popup .unity-button {
- min-width: 137px;
-}
-
-.title-text {
- -unity-font-definition: url("project://database/Assets/UI/Fonts/Inter-SemiBold.ttf?fileID=12800000&guid=3b458681b475c476ea29f3244c5c85da&type=3#Inter-SemiBold");
- margin-top: 30px;
- margin-bottom: 30px;
- color: rgb(255, 255, 255);
-}
-
-.lsp-logo {
- position: absolute;
- width: 330px;
- height: 82px;
- top: 58px;
- left: 52px;
- background-image: url("project://database/Assets/UI/Images/LetterSpell_smallLogo.png?fileID=2800000&guid=75dc9c01c37ed4403948da36191f22df&type=3#LetterSpell_smallLogo");
-}
-
-.lsp-debug-view {
- font-size: 24px;
-}
-
-.lsp-debug-view .unity-button {
- padding-top: 10px;
- padding-bottom: 10px;
- padding-right: 20px;
- padding-left: 20px;
-}
-
-.choice-button-container {
- flex-direction: row;
-}
-
-.start-game-button {
-}
-
-#pauseButtonIcon {
- background-image: url("project://database/Assets/UI/Images/PauseIcon.png?fileID=2800000&guid=c9d90502b54df4fb8a6679c396a05fc0&type=3#PauseIcon");
- width: 45px;
- height: 47px;
- -unity-background-scale-mode: scale-to-fit;
-}
-
-.lsp-popup .unity-label {
- -unity-text-align: middle-center;
- -unity-font-definition: url("project://database/Assets/UI/Fonts/Inter-SemiBold.ttf?fileID=12800000&guid=3b458681b475c476ea29f3244c5c85da&type=3#Inter-SemiBold");
- margin-top: 30px;
- margin-bottom: 65px;
-}
-
-.purple:active {
- background-color: rgb(130, 68, 243);
- color: rgb(255, 255, 255);
-}
-
-.unity-base-field {
- margin-top: 30px;
- margin-bottom: 30px;
-}
-
-.unity-base-field {
- flex-direction: var(--lsp-row);
-}
-
-.lsp-button-strip-field__button-container {
- flex-direction: var(--lsp-row);
-}
-
-.lsp-button-strip-field__button {
- background-color: rgb(161, 116, 243);
- color: rgb(255, 255, 255);
- margin-left: 0;
- margin-right: 0;
- margin-top: 0;
- margin-bottom: 0;
-}
-
-.lsp-button-strip-field__button:active {
- background-color: rgb(116, 45, 243);
-}
-
-.lsp-button-strip-field__button--left {
- border-radius: 30px;
- border-width: 10px;
- border-right-width: 5px;
- border-top-right-radius: 0;
- border-bottom-right-radius: 0;
-}
-
-.lsp-dir-rtl .lsp-button-strip-field__button--left{
- border-radius: 30px;
- border-width: 10px;
- border-left-width: 5px;
- border-top-left-radius: 0;
- border-bottom-left-radius: 0;
-}
-
-.lsp-button-strip-field__button--right {
- border-radius: 30px;
- border-width: 10px;
- border-top-left-radius: 0;
- border-bottom-left-radius: 0;
- border-left-width: 5px;
-}
-
-.lsp-dir-rtl .lsp-button-strip-field__button--right {
- border-radius: 30px;
- border-width: 10px;
- border-right-width: 5px;
- border-top-right-radius: 0;
- border-bottom-right-radius: 0;
-}
-
-.lsp-button-strip-field__button:checked {
- background-color: rgb(116, 45, 243);
-}
-
-.unity-radio-button__label {
- min-width: 0;
- margin-right: 30px;
- margin-left: 30px;
-}
-
-.unity-radio-button {
- flex-direction: var(--lsp-row-reverse);
- margin-top: 0;
- margin-bottom: 0;
-}
-
-.unity-foldout__toggle > .unity-toggle__input:focus:checked > .unity-toggle__checkmark {
- background-image: url("project://database/Assets/UI/Images/Toggle-Checkmark.png?fileID=2800000&guid=c049f948873dd43099c96def60ac9c31&type=3#Toggle-Checkmark");
-}
-
-.unity-base-popup-field__arrow {
- width: 50px;
- height: 50px;
- margin-right: 30px;
- margin-left: 30px;
- background-image: url("project://database/Assets/UI/Images/Dropdown-Arrow.png?fileID=2800000&guid=29e091d0e13ce4d928a786bc1ff99351&type=3#Dropdown-Arrow");
- margin-top: 14px;
- margin-bottom: 14px;
-}
-
-.row {
- flex-direction: var(--lsp-row);
-}
-
-#closeSettingsButton {
- margin-left: 0;
-}
-
-:root.bold-text {
- -unity-font-style: bold;
-}
-
-.unity-base-dropdown__item {
-}
-
-.unity-base-dropdown__checkmark {
- margin-top: 30px;
- margin-right: 30px;
- margin-bottom: 30px;
- margin-left: 30px;
- width: 50px;
- height: 50px;
-}
-
-.unity-base-dropdown__item:checked > .unity-base-dropdown__item-content > .unity-base-dropdown__label {
-}
-
-.unity-base-dropdown__item > .unity-base-dropdown__item-content > .unity-base-dropdown__label {
- margin-left: 80px;
-}
-
-.lsp-stack-view-Transition {
- position: absolute;
- top: 0;
- left: 0;
- width: 100%;
- height: 100%;
- background-color: rgb(2, 197, 132);
-}
-
-#splashSubTitle {
- position: absolute;
- top: 50%;
- left: 0;
- right: 0;
- -unity-text-align: upper-center;
- margin-top: 70px;
- color: rgb(255, 255, 255);
-}
-
-#successPill {
- background-color: rgb(255, 255, 255);
- border-top-left-radius: 38px;
- border-top-right-radius: 38px;
- border-bottom-right-radius: 38px;
- border-bottom-left-radius: 38px;
- padding-right: 38px;
- padding-left: 38px;
- padding-top: 4px;
- padding-bottom: 4px;
- -unity-font-definition: url("project://database/Assets/UI/Fonts/Inter-SemiBold.ttf?fileID=12800000&guid=3b458681b475c476ea29f3244c5c85da&type=3#Inter-SemiBold");
- flex-direction: var(--lsp-row);
- justify-content: center;
- align-items: center;
-}
-
-#successPillCheckmark {
- width: 52px;
- height: 47px;
- background-image: url("project://database/Assets/UI/Images/Success-Check.png?fileID=2800000&guid=8eb6e6371b15149a7b6e3cd6117749c1&type=3#Success-Check");
- margin-right: 15px;
-}
-
-.success-pill__label {
- padding-top: 2px;
- padding-bottom: 2px;
- margin-top: 0;
- margin-bottom: 0;
-}
-
-#clueContainer {
- align-items: center;
- padding-top: 168px;
- padding-bottom: 30px;
-}
-
-#clueLabel {
-}
-
-#loginNameField {
- flex-direction: column;
-}
-
-#loginNameField .unity-base-field__label {
- -unity-text-align: middle-center;
- color: rgb(255, 255, 255);
- -unity-font-definition: url("project://database/Assets/UI/Fonts/Inter-SemiBold.ttf?fileID=12800000&guid=3b458681b475c476ea29f3244c5c85da&type=3#Inter-SemiBold");
- margin-bottom: 30px;
-}
diff --git a/Assets/Resources/UITk/Themes/Common.meta b/Assets/Resources/UITk/Themes/Tokens.meta
similarity index 77%
rename from Assets/Resources/UITk/Themes/Common.meta
rename to Assets/Resources/UITk/Themes/Tokens.meta
index 5b5da92..fb2c531 100644
--- a/Assets/Resources/UITk/Themes/Common.meta
+++ b/Assets/Resources/UITk/Themes/Tokens.meta
@@ -1,5 +1,5 @@
fileFormatVersion: 2
-guid: 92dfe9516ccaa4e8dbe410e180f2f011
+guid: 3acba4d8fef5644a28d226244f4fc729
folderAsset: yes
DefaultImporter:
externalObjects: {}
diff --git a/Assets/Resources/UITk/Themes/Tokens/LetterSpellStyle.Tokens.Common.uss b/Assets/Resources/UITk/Themes/Tokens/LetterSpellStyle.Tokens.Common.uss
new file mode 100644
index 0000000..24e287a
--- /dev/null
+++ b/Assets/Resources/UITk/Themes/Tokens/LetterSpellStyle.Tokens.Common.uss
@@ -0,0 +1,40 @@
+:root {
+ /* Spacing */
+ --lsp-spacing-xs: 4px;
+ --lsp-spacing-sm: 15px;
+ --lsp-spacing-md: 30px;
+ --lsp-spacing-lg: 70px;
+ --lsp-spacing-xl: 100px;
+ --lsp-spacing-xxl: 140px;
+
+ /* Dropdown */
+ --lsp-popup-field-arrow-width-md: 50px;
+
+ /* Size */
+ --lsp-field-label-min-width: 680px;
+
+ /* Border */
+ --lsp-border-radius-xs: 7px;
+ --lsp-border-radius-sm: 20px;
+ --lsp-border-radius-md: 30px;
+ --lsp-border-radius-lg: 33px;
+ --lsp-border-radius-xl: 38px;
+
+ --lsp-border-width-sm: 6px;
+ --lsp-border-width-md-half: 5px;
+ --lsp-border-width-md: 10px;
+
+ /* Checkmark */
+ --lsp-checkmark-size-xs: 20px;
+ --lsp-checkmark-size-sm: 50px;
+ --lsp-checkmark-size-md: 70px;
+
+ --lsp-font-size-md: 64px;
+
+ --lsp-font-bold: url("project://database/Assets/UI/Fonts/Inter-SemiBold.ttf?fileID=12800000&guid=3b458681b475c476ea29f3244c5c85da&type=3#Inter-SemiBold");
+
+ /* Slider */
+ --lsp-slider-groove-height-md: 10px;
+ --lsp-slider-thumb-width-md: 40px;
+ --lsp-slider-thumb-height-md: 70px;
+}
\ No newline at end of file
diff --git a/Assets/Resources/UITk/Themes/GreenStyle/GreenStyle.tss.meta b/Assets/Resources/UITk/Themes/Tokens/LetterSpellStyle.Tokens.Common.uss.meta
similarity index 60%
rename from Assets/Resources/UITk/Themes/GreenStyle/GreenStyle.tss.meta
rename to Assets/Resources/UITk/Themes/Tokens/LetterSpellStyle.Tokens.Common.uss.meta
index 3f6c994..173c1f0 100644
--- a/Assets/Resources/UITk/Themes/GreenStyle/GreenStyle.tss.meta
+++ b/Assets/Resources/UITk/Themes/Tokens/LetterSpellStyle.Tokens.Common.uss.meta
@@ -1,5 +1,5 @@
fileFormatVersion: 2
-guid: dbe9ef9eec5e742a7b22a1718098953e
+guid: 5086368f2b96c4532a49031c4b2be5e3
ScriptedImporter:
internalIDToNameTable: []
externalObjects: {}
@@ -7,5 +7,6 @@ ScriptedImporter:
userData:
assetBundleName:
assetBundleVariant:
- script: {fileID: 12388, guid: 0000000000000000e000000000000000, type: 0}
+ script: {fileID: 12385, guid: 0000000000000000e000000000000000, type: 0}
disableValidation: 0
+ unsupportedSelectorAction: 0
diff --git a/Assets/Resources/UITk/Themes/Tokens/LetterSpellStyle.Tokens.Dark.uss b/Assets/Resources/UITk/Themes/Tokens/LetterSpellStyle.Tokens.Dark.uss
new file mode 100644
index 0000000..ba6737d
--- /dev/null
+++ b/Assets/Resources/UITk/Themes/Tokens/LetterSpellStyle.Tokens.Dark.uss
@@ -0,0 +1,3 @@
+:root {
+ --lsp-color-white: white;
+}
\ No newline at end of file
diff --git a/Assets/Resources/UITk/Themes/Tokens/LetterSpellStyle.Tokens.Dark.uss.meta b/Assets/Resources/UITk/Themes/Tokens/LetterSpellStyle.Tokens.Dark.uss.meta
new file mode 100644
index 0000000..700e35e
--- /dev/null
+++ b/Assets/Resources/UITk/Themes/Tokens/LetterSpellStyle.Tokens.Dark.uss.meta
@@ -0,0 +1,12 @@
+fileFormatVersion: 2
+guid: eb9cdc07563014c08bfc45c8e120b908
+ScriptedImporter:
+ internalIDToNameTable: []
+ externalObjects: {}
+ serializedVersion: 2
+ userData:
+ assetBundleName:
+ assetBundleVariant:
+ script: {fileID: 12385, guid: 0000000000000000e000000000000000, type: 0}
+ disableValidation: 0
+ unsupportedSelectorAction: 0
diff --git a/Assets/Resources/UITk/Themes/Tokens/LetterSpellStyle.Tokens.Green.uss b/Assets/Resources/UITk/Themes/Tokens/LetterSpellStyle.Tokens.Green.uss
new file mode 100644
index 0000000..c47cafd
--- /dev/null
+++ b/Assets/Resources/UITk/Themes/Tokens/LetterSpellStyle.Tokens.Green.uss
@@ -0,0 +1,38 @@
+:root {
+ --lsp-color-green: rgb(2, 197, 132);
+ --lsp-color-transparent: rgba(0, 0, 0, 0);
+ --lsp-color-white: white;
+ --lsp-color-black: black;
+ --lsp-color-gray-164: rgb(164, 164, 164);
+ --lsp-color-yellow-light: rgb(255, 251, 232);
+ --lsp-color-yellow-lighter-130: rgb(255, 241, 200);
+ --lsp-color-yellow-lighter-110: rgb(242, 200, 0);
+ --lsp-color-yellow: rgb(220, 180, 0);
+ --lsp-color-yellow-darker-120: rgb(200, 160, 0);
+ --lsp-color-yellow-darker-130: rgb(170, 130, 0);
+ --lsp-color-yellow-darker-180: rgb(120, 80, 0);
+ --lsp-color-blue-600: #59a7f6;
+ --lsp-color-purple: rgb(161, 116, 244);
+ --lsp-color-purple-lighter-130: rgb(191, 156, 255);
+ --lsp-color-purple-darker-120: rgb(121, 76, 194);
+ --lsp-color-blue: rgb(1, 168, 255);
+ --lsp-color-blue-lighter-130: rgb(114, 207, 255);
+ --lsp-color-blue-lighter-110: rgb(57, 188, 255);
+ --lsp-color-blue-darker-120: rgb(0, 118, 197);
+ --lsp-color-blue-light: rgb(114, 207, 255);
+
+ /* Images */
+ --lsp-images-splash: url("project://database/Assets/UI/Images/Splash-Screen.png");
+ --lsp-images-logo: url("project://database/Assets/UI/Images/LetterSpell_smallLogo.png?fileID=2800000&guid=75dc9c01c37ed4403948da36191f22df&type=3#LetterSpell_smallLogo");
+ --lsp-images-logo-w: 330px;
+ --lsp-images-logo-h: 82px;
+
+ --unity-icons-dropdown: url("project://database/Assets/UI/Images/Dropdown-Arrow.png?fileID=2800000&guid=29e091d0e13ce4d928a786bc1ff99351&type=3#Dropdown-Arrow");
+ --lsp-icons-pause: url("project://database/Assets/UI/Images/PauseIcon.png?fileID=2800000&guid=c9d90502b54df4fb8a6679c396a05fc0&type=3#PauseIcon");
+ --lsp-icons-pause-w: 45px;
+ --lsp-icons-pause-h: 44px;
+
+ --lsp-icons-success-check: url("project://database/Assets/UI/Images/Success-Check.png?fileID=2800000&guid=8eb6e6371b15149a7b6e3cd6117749c1&type=3#Success-Check");
+ --lsp-icons-success-check-w: 52px;
+ --lsp-icons-success-check-h: 47px;
+}
\ No newline at end of file
diff --git a/Assets/Resources/UITk/Themes/Tokens/LetterSpellStyle.Tokens.Green.uss.meta b/Assets/Resources/UITk/Themes/Tokens/LetterSpellStyle.Tokens.Green.uss.meta
new file mode 100644
index 0000000..50fb87f
--- /dev/null
+++ b/Assets/Resources/UITk/Themes/Tokens/LetterSpellStyle.Tokens.Green.uss.meta
@@ -0,0 +1,12 @@
+fileFormatVersion: 2
+guid: 13a78ab1f0e3f4b2585e2181e2a6f7d0
+ScriptedImporter:
+ internalIDToNameTable: []
+ externalObjects: {}
+ serializedVersion: 2
+ userData:
+ assetBundleName:
+ assetBundleVariant:
+ script: {fileID: 12385, guid: 0000000000000000e000000000000000, type: 0}
+ disableValidation: 0
+ unsupportedSelectorAction: 0
diff --git a/Assets/Resources/UITk/UI.meta b/Assets/Resources/UITk/UI.meta
new file mode 100644
index 0000000..5bb7c23
--- /dev/null
+++ b/Assets/Resources/UITk/UI.meta
@@ -0,0 +1,8 @@
+fileFormatVersion: 2
+guid: 0bee443dbd0124af1b1242f0feb4a789
+folderAsset: yes
+DefaultImporter:
+ externalObjects: {}
+ userData:
+ assetBundleName:
+ assetBundleVariant:
diff --git a/Assets/Resources/UITk/UI/ExitGameView.uxml b/Assets/Resources/UITk/UI/ExitGameView.uxml
new file mode 100644
index 0000000..8bbdfaa
--- /dev/null
+++ b/Assets/Resources/UITk/UI/ExitGameView.uxml
@@ -0,0 +1,22 @@
+
+
+
+
diff --git a/Assets/Resources/UITk/UI/ExitGameView.uxml.meta b/Assets/Resources/UITk/UI/ExitGameView.uxml.meta
new file mode 100644
index 0000000..d86ff4d
--- /dev/null
+++ b/Assets/Resources/UITk/UI/ExitGameView.uxml.meta
@@ -0,0 +1,10 @@
+fileFormatVersion: 2
+guid: 66385de7d2e1b46fbab7805869f4ae2b
+ScriptedImporter:
+ internalIDToNameTable: []
+ externalObjects: {}
+ serializedVersion: 2
+ userData:
+ assetBundleName:
+ assetBundleVariant:
+ script: {fileID: 13804, guid: 0000000000000000e000000000000000, type: 0}
diff --git a/Assets/Resources/UITk/UI/GameView.uss b/Assets/Resources/UITk/UI/GameView.uss
new file mode 100644
index 0000000..bde782c
--- /dev/null
+++ b/Assets/Resources/UITk/UI/GameView.uss
@@ -0,0 +1,22 @@
+:root {
+}
+
+#clueContainer {
+ align-items: center;
+ padding-top: var(--lsp-spacing-xxl);
+ padding-bottom: var(--lsp-spacing-md);
+}
+
+#successPillCheckmark {
+ width: var(--lsp-icons-success-check-w);
+ height: var(--lsp-icons-success-check-h);
+ background-image: var(--lsp-icons-success-check);
+ margin-right: var(--lsp-spacing-sm);
+}
+
+.success-pill__label {
+ padding-top: 2px;
+ padding-bottom: 2px;
+ margin-top: 0;
+ margin-bottom: 0;
+}
\ No newline at end of file
diff --git a/Assets/Resources/UITk/UI/GameView.uss.meta b/Assets/Resources/UITk/UI/GameView.uss.meta
new file mode 100644
index 0000000..7d9bed5
--- /dev/null
+++ b/Assets/Resources/UITk/UI/GameView.uss.meta
@@ -0,0 +1,12 @@
+fileFormatVersion: 2
+guid: a78fa2696ccab406aa7d8e0085f51cb7
+ScriptedImporter:
+ internalIDToNameTable: []
+ externalObjects: {}
+ serializedVersion: 2
+ userData:
+ assetBundleName:
+ assetBundleVariant:
+ script: {fileID: 12385, guid: 0000000000000000e000000000000000, type: 0}
+ disableValidation: 0
+ unsupportedSelectorAction: 0
diff --git a/Assets/Resources/UITk/UI/GameView.uxml b/Assets/Resources/UITk/UI/GameView.uxml
new file mode 100644
index 0000000..fddd592
--- /dev/null
+++ b/Assets/Resources/UITk/UI/GameView.uxml
@@ -0,0 +1,34 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Assets/Resources/UITk/UI/GameView.uxml.meta b/Assets/Resources/UITk/UI/GameView.uxml.meta
new file mode 100644
index 0000000..88714f6
--- /dev/null
+++ b/Assets/Resources/UITk/UI/GameView.uxml.meta
@@ -0,0 +1,10 @@
+fileFormatVersion: 2
+guid: 6c0478d0e80b24706984a61410830aac
+ScriptedImporter:
+ internalIDToNameTable: []
+ externalObjects: {}
+ serializedVersion: 2
+ userData:
+ assetBundleName:
+ assetBundleVariant:
+ script: {fileID: 13804, guid: 0000000000000000e000000000000000, type: 0}
diff --git a/Assets/Resources/UITk/UI/LoginView.uss b/Assets/Resources/UITk/UI/LoginView.uss
new file mode 100644
index 0000000..8a5291c
--- /dev/null
+++ b/Assets/Resources/UITk/UI/LoginView.uss
@@ -0,0 +1,13 @@
+:root {
+}
+
+#userNameField {
+ flex-direction: column;
+}
+
+#userNameField > .unity-base-field__label {
+ -unity-text-align: middle-center;
+ color: var(--lsp-secondary-text-color);
+ -unity-font-definition: var(--lsp-font-bold);
+ margin-bottom: var(--lsp-spacing-md);
+}
\ No newline at end of file
diff --git a/Assets/Resources/UITk/UI/LoginView.uss.meta b/Assets/Resources/UITk/UI/LoginView.uss.meta
new file mode 100644
index 0000000..f8f4db9
--- /dev/null
+++ b/Assets/Resources/UITk/UI/LoginView.uss.meta
@@ -0,0 +1,12 @@
+fileFormatVersion: 2
+guid: d15e33b7f758a47be978203fb8bd9ec3
+ScriptedImporter:
+ internalIDToNameTable: []
+ externalObjects: {}
+ serializedVersion: 2
+ userData:
+ assetBundleName:
+ assetBundleVariant:
+ script: {fileID: 12385, guid: 0000000000000000e000000000000000, type: 0}
+ disableValidation: 0
+ unsupportedSelectorAction: 0
diff --git a/Assets/Resources/UITk/UI/LoginView.uxml b/Assets/Resources/UITk/UI/LoginView.uxml
new file mode 100644
index 0000000..e9773b5
--- /dev/null
+++ b/Assets/Resources/UITk/UI/LoginView.uxml
@@ -0,0 +1,18 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Assets/Resources/UITk/UI/LoginView.uxml.meta b/Assets/Resources/UITk/UI/LoginView.uxml.meta
new file mode 100644
index 0000000..8622ade
--- /dev/null
+++ b/Assets/Resources/UITk/UI/LoginView.uxml.meta
@@ -0,0 +1,10 @@
+fileFormatVersion: 2
+guid: 077667c70092f4209abb73da80a8faad
+ScriptedImporter:
+ internalIDToNameTable: []
+ externalObjects: {}
+ serializedVersion: 2
+ userData:
+ assetBundleName:
+ assetBundleVariant:
+ script: {fileID: 13804, guid: 0000000000000000e000000000000000, type: 0}
diff --git a/Assets/Resources/UITk/UI/MainMenu.uss b/Assets/Resources/UITk/UI/MainMenu.uss
new file mode 100644
index 0000000..bf8cdf0
--- /dev/null
+++ b/Assets/Resources/UITk/UI/MainMenu.uss
@@ -0,0 +1,10 @@
+:root {
+}
+
+#choiceButtonContainer {
+ flex-direction: row;
+}
+
+.choice-button {
+ color: var(--unity-colors-button-color);
+}
diff --git a/Assets/Resources/UITk/UI/MainMenu.uss.meta b/Assets/Resources/UITk/UI/MainMenu.uss.meta
new file mode 100644
index 0000000..e0b669f
--- /dev/null
+++ b/Assets/Resources/UITk/UI/MainMenu.uss.meta
@@ -0,0 +1,12 @@
+fileFormatVersion: 2
+guid: 4538736f0e9494db1a7b76ee9349bde4
+ScriptedImporter:
+ internalIDToNameTable: []
+ externalObjects: {}
+ serializedVersion: 2
+ userData:
+ assetBundleName:
+ assetBundleVariant:
+ script: {fileID: 12385, guid: 0000000000000000e000000000000000, type: 0}
+ disableValidation: 0
+ unsupportedSelectorAction: 0
diff --git a/Assets/Resources/UITk/UI/MainMenu.uxml b/Assets/Resources/UITk/UI/MainMenu.uxml
new file mode 100644
index 0000000..5a4ec4a
--- /dev/null
+++ b/Assets/Resources/UITk/UI/MainMenu.uxml
@@ -0,0 +1,25 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Assets/Resources/UITk/UI/MainMenu.uxml.meta b/Assets/Resources/UITk/UI/MainMenu.uxml.meta
new file mode 100644
index 0000000..d54429f
--- /dev/null
+++ b/Assets/Resources/UITk/UI/MainMenu.uxml.meta
@@ -0,0 +1,10 @@
+fileFormatVersion: 2
+guid: 04d189e35bac141deb5b14501898b9b1
+ScriptedImporter:
+ internalIDToNameTable: []
+ externalObjects: {}
+ serializedVersion: 2
+ userData:
+ assetBundleName:
+ assetBundleVariant:
+ script: {fileID: 13804, guid: 0000000000000000e000000000000000, type: 0}
diff --git a/Assets/Resources/UITk/UI/MainView.uss b/Assets/Resources/UITk/UI/MainView.uss
new file mode 100644
index 0000000..e98a187
--- /dev/null
+++ b/Assets/Resources/UITk/UI/MainView.uss
@@ -0,0 +1,10 @@
+.lsp-debug-view {
+ font-size: 24px;
+}
+
+.lsp-debug-view .unity-button {
+ padding-top: 10px;
+ padding-bottom: 10px;
+ padding-right: 20px;
+ padding-left: 20px;
+}
\ No newline at end of file
diff --git a/Assets/Resources/UITk/Themes/LetterSpellTheme.uss.meta b/Assets/Resources/UITk/UI/MainView.uss.meta
similarity index 100%
rename from Assets/Resources/UITk/Themes/LetterSpellTheme.uss.meta
rename to Assets/Resources/UITk/UI/MainView.uss.meta
diff --git a/Assets/Resources/UITk/UI/MainView.uxml b/Assets/Resources/UITk/UI/MainView.uxml
new file mode 100644
index 0000000..d2bdc21
--- /dev/null
+++ b/Assets/Resources/UITk/UI/MainView.uxml
@@ -0,0 +1,31 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Assets/Resources/UITk/MainView.uxml.meta b/Assets/Resources/UITk/UI/MainView.uxml.meta
similarity index 100%
rename from Assets/Resources/UITk/MainView.uxml.meta
rename to Assets/Resources/UITk/UI/MainView.uxml.meta
diff --git a/Assets/Resources/UITk/UI/PopupWindow.uss b/Assets/Resources/UITk/UI/PopupWindow.uss
new file mode 100644
index 0000000..ab3d85e
--- /dev/null
+++ b/Assets/Resources/UITk/UI/PopupWindow.uss
@@ -0,0 +1,23 @@
+:root {
+}
+
+.lsp-popup-content .unity-label {
+ -unity-text-align: middle-center;
+ -unity-font-definition: var(--lsp-font-bold);
+ margin-top: var(--lsp-spacing-md);
+ margin-bottom: var(--lsp-spacing-lg);
+}
+
+.lsp-popup-content .unity-button {
+ min-width: 137px;
+}
+
+
+
+.lsp-button-box {
+ flex-grow: 1;
+ flex-direction: row;
+ margin-top: 10px;
+ align-items: center;
+ justify-content: center;
+}
diff --git a/Assets/Resources/UITk/UI/PopupWindow.uss.meta b/Assets/Resources/UITk/UI/PopupWindow.uss.meta
new file mode 100644
index 0000000..652fead
--- /dev/null
+++ b/Assets/Resources/UITk/UI/PopupWindow.uss.meta
@@ -0,0 +1,12 @@
+fileFormatVersion: 2
+guid: 6f40ef823557b4df8b9928233720a4ad
+ScriptedImporter:
+ internalIDToNameTable: []
+ externalObjects: {}
+ serializedVersion: 2
+ userData:
+ assetBundleName:
+ assetBundleVariant:
+ script: {fileID: 12385, guid: 0000000000000000e000000000000000, type: 0}
+ disableValidation: 0
+ unsupportedSelectorAction: 0
diff --git a/Assets/Resources/UITk/UI/ResultView.uxml b/Assets/Resources/UITk/UI/ResultView.uxml
new file mode 100644
index 0000000..a0775fc
--- /dev/null
+++ b/Assets/Resources/UITk/UI/ResultView.uxml
@@ -0,0 +1,31 @@
+
+
+
+
diff --git a/Assets/Resources/UITk/UI/ResultView.uxml.meta b/Assets/Resources/UITk/UI/ResultView.uxml.meta
new file mode 100644
index 0000000..cd89afd
--- /dev/null
+++ b/Assets/Resources/UITk/UI/ResultView.uxml.meta
@@ -0,0 +1,10 @@
+fileFormatVersion: 2
+guid: dc939db8da5384827b657b3c5a50ebbe
+ScriptedImporter:
+ internalIDToNameTable: []
+ externalObjects: {}
+ serializedVersion: 2
+ userData:
+ assetBundleName:
+ assetBundleVariant:
+ script: {fileID: 13804, guid: 0000000000000000e000000000000000, type: 0}
diff --git a/Assets/Resources/UITk/UI/SettingsView.uss b/Assets/Resources/UITk/UI/SettingsView.uss
new file mode 100644
index 0000000..de1b98c
--- /dev/null
+++ b/Assets/Resources/UITk/UI/SettingsView.uss
@@ -0,0 +1,16 @@
+:root {
+ --lsp-colors-button_strip_field_button-background: var(--lsp-primary-accent-color);
+}
+
+#root {
+ padding: var(--lsp-spacing-lg);
+ padding-bottom: var(--lsp-spacing-xs);
+}
+
+.unity-radio-button .unity-base-field__label {
+ min-width: 0;
+}
+
+.lsp-background {
+ background-color: var(--lsp-color-yellow-light);
+}
diff --git a/Assets/Resources/UITk/UI/SettingsView.uss.meta b/Assets/Resources/UITk/UI/SettingsView.uss.meta
new file mode 100644
index 0000000..fa27394
--- /dev/null
+++ b/Assets/Resources/UITk/UI/SettingsView.uss.meta
@@ -0,0 +1,12 @@
+fileFormatVersion: 2
+guid: 2444a54c4bf334e1f895f1370345ef13
+ScriptedImporter:
+ internalIDToNameTable: []
+ externalObjects: {}
+ serializedVersion: 2
+ userData:
+ assetBundleName:
+ assetBundleVariant:
+ script: {fileID: 12385, guid: 0000000000000000e000000000000000, type: 0}
+ disableValidation: 0
+ unsupportedSelectorAction: 0
diff --git a/Assets/Resources/UITk/UI/SettingsView.uxml b/Assets/Resources/UITk/UI/SettingsView.uxml
new file mode 100644
index 0000000..b29d65c
--- /dev/null
+++ b/Assets/Resources/UITk/UI/SettingsView.uxml
@@ -0,0 +1,145 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Assets/Resources/UITk/UI/SettingsView.uxml.meta b/Assets/Resources/UITk/UI/SettingsView.uxml.meta
new file mode 100644
index 0000000..76ea2ee
--- /dev/null
+++ b/Assets/Resources/UITk/UI/SettingsView.uxml.meta
@@ -0,0 +1,10 @@
+fileFormatVersion: 2
+guid: accec2036303345889bb641ccfc87786
+ScriptedImporter:
+ internalIDToNameTable: []
+ externalObjects: {}
+ serializedVersion: 2
+ userData:
+ assetBundleName:
+ assetBundleVariant:
+ script: {fileID: 13804, guid: 0000000000000000e000000000000000, type: 0}
diff --git a/Assets/Resources/UITk/UI/SplashScreen.uss b/Assets/Resources/UITk/UI/SplashScreen.uss
new file mode 100644
index 0000000..d456d84
--- /dev/null
+++ b/Assets/Resources/UITk/UI/SplashScreen.uss
@@ -0,0 +1,21 @@
+:root {
+}
+
+.lsp-splashscreen-bg {
+ position: absolute;
+ top: 0;
+ right: 0;
+ left: 0;
+ bottom: 0;
+ background-image: var(--lsp-images-splash);
+}
+
+.lsp-splashscreen-subtitle {
+ position: absolute;
+ top: 60%;
+ left: 0;
+ right: 0;
+ -unity-text-align: upper-center;
+ color: var(--lsp-secondary-text-color);
+}
+
diff --git a/Assets/Resources/UITk/UI/SplashScreen.uss.meta b/Assets/Resources/UITk/UI/SplashScreen.uss.meta
new file mode 100644
index 0000000..85dc8aa
--- /dev/null
+++ b/Assets/Resources/UITk/UI/SplashScreen.uss.meta
@@ -0,0 +1,12 @@
+fileFormatVersion: 2
+guid: a9755bc03de5f448cb7ae43e99ccbcb8
+ScriptedImporter:
+ internalIDToNameTable: []
+ externalObjects: {}
+ serializedVersion: 2
+ userData:
+ assetBundleName:
+ assetBundleVariant:
+ script: {fileID: 12385, guid: 0000000000000000e000000000000000, type: 0}
+ disableValidation: 0
+ unsupportedSelectorAction: 0
diff --git a/Assets/Resources/UITk/UI/SplashScreen.uxml b/Assets/Resources/UITk/UI/SplashScreen.uxml
new file mode 100644
index 0000000..ee98eaa
--- /dev/null
+++ b/Assets/Resources/UITk/UI/SplashScreen.uxml
@@ -0,0 +1,7 @@
+
+
+
+
+
+
+
diff --git a/Assets/Resources/UITk/UI/SplashScreen.uxml.meta b/Assets/Resources/UITk/UI/SplashScreen.uxml.meta
new file mode 100644
index 0000000..70d817e
--- /dev/null
+++ b/Assets/Resources/UITk/UI/SplashScreen.uxml.meta
@@ -0,0 +1,10 @@
+fileFormatVersion: 2
+guid: 089a8250abff34490bb8b7e2fdb2a162
+ScriptedImporter:
+ internalIDToNameTable: []
+ externalObjects: {}
+ serializedVersion: 2
+ userData:
+ assetBundleName:
+ assetBundleVariant:
+ script: {fileID: 13804, guid: 0000000000000000e000000000000000, type: 0}
diff --git a/Assets/Scripts/Screen Reader/UITk/UITkAccessibilityManager.cs b/Assets/Scripts/Screen Reader/UITk/UITkAccessibilityManager.cs
index a1077a8..f37a9b9 100644
--- a/Assets/Scripts/Screen Reader/UITk/UITkAccessibilityManager.cs
+++ b/Assets/Scripts/Screen Reader/UITk/UITkAccessibilityManager.cs
@@ -100,6 +100,11 @@ void OnNodeFocusChanged(AccessibilityNode node)
}
}
+ public AccessibilityNode GetNodeForVisualElement(VisualElement element)
+ {
+ return m_AccessibilityUpdater.GetNodeForVisualElement(element);
+ }
+
public VisualElement GetVisualElementForNode(AccessibilityNode node)
{
return m_AccessibilityUpdater.GetVisualElementForNode(node);
diff --git a/Assets/Scripts/UITk/Card.cs b/Assets/Scripts/UITk/Card.cs
deleted file mode 100644
index cc08c61..0000000
--- a/Assets/Scripts/UITk/Card.cs
+++ /dev/null
@@ -1,740 +0,0 @@
-using System;
-using System.Linq;
-using UnityEngine;
-using UnityEngine.Accessibility;
-using UnityEngine.UIElements;
-using Unity.Samples.ScreenReader;
-using UnityEngine.Localization;
-using UnityEngine.Localization.Settings;
-using UnityEngine.Localization.SmartFormat.PersistentVariables;
-
-namespace Unity.Samples.LetterSpell
-{
- class UITkLetterCard : AccessibleVisualElement
- {
- Label m_TextElement;
- Vector2 m_Start;
- protected bool m_Active;
- VisualElement m_Element;
-
- CardListView cardListView => parent as CardListView;
-
- // [RegisterAccessible]
- // class LetterCardAccessibleElement : AccessibleElement
- // {
- // public override string GetLabel() => (owner as UITkLetterCard).text;
- // }
-
- bool m_Selected;
-
- public bool selected
- {
- get => m_Selected;
- set
- {
- if (m_Selected == value)
- {
- return;
- }
-
- m_Selected = value;
-
- if (value)
- {
- Focus();
- }
-
- UpdateSelectedState();
- }
- }
-
- void UpdateSelectedState()
- {
- EnableInClassList("selected", selected);
- }
-
- public string text
- {
- get => m_TextElement.text;
- set
- {
- m_TextElement.text = value;
- accessible.label = value;
- }
- }
-
- public event Action dropped;
-
- public void Select()
- {
- if (cardListView.selectedCard != this)
- {
- cardListView.selectedCard = this;
-
- accessible.hint = LocalizationSettings.StringDatabase.GetLocalizedString("Game Text", "LETTER_CARD_HINT_SELECTED");
- }
- }
-
- public void Unselect()
- {
- if (this == cardListView.selectedCard)
- {
- cardListView.selectedCard = null;
-
- accessible.hint = LocalizationSettings.StringDatabase.GetLocalizedString("Game Text", "LETTER_CARD_HINT_UNSELECTED");
- }
- }
-
- public UITkLetterCard()
- {
- m_TextElement = new Label();
- Add(m_TextElement);
- AddToClassList("lsp-letter-card");
- AddToClassList("lsp-card-view-item");
-
- focusable = true;
-
- style.position = Position.Absolute;
-
- RegisterCallbacksOnTarget();
- RegisterCallback(OnAttachToPanel);
-
- // Accessibility
- m_TextElement.GetOrCreateAccessibleProperties().ignored = true;
-
- accessible.hint = LocalizationSettings.StringDatabase.GetLocalizedString("Game Text", "LETTER_CARD_HINT_UNSELECTED");
- accessible.selected += () =>
- {
- if (!selected)
- {
- Select();
- }
- else
- {
- Unselect();
- }
-
- return true;
- };
- }
-
- bool m_Animated;
-
- bool animated
- {
- get => m_Animated;
- set
- {
- if (m_Animated == value)
- {
- return;
- }
-
- m_Animated = value;
- EnableInClassList( "animated", animated);
- }
- }
-
- void OnAttachToPanel(AttachToPanelEvent e)
- {
- cardListView.DoLayout();
-
- // Make them animated.
- // TODO: FIX ANIMATION WHEN STARTING A GAME
- // schedule.Execute(() => animated = true).ExecuteLater(500);
- }
-
- protected Rect CalculatePosition(float x, float y, float width, float height)
- {
- var rect = new Rect(x, y, width, height);
-
- /*if (clampToParentEdges)
- {
- Rect shadowRect = hierarchy.parent.layout.;
- rect.x = Mathf.Clamp(rect.x, shadowRect.xMin, Mathf.Abs(shadowRect.xMax - rect.width));
- rect.y = Mathf.Clamp(rect.y, shadowRect.yMin, Mathf.Abs(shadowRect.yMax - rect.height));
-
- // Reset size, we never intended to change them in the first place.
- rect.width = width;
- rect.height = height;
- }*/
-
- return rect;
- }
-
- protected void RegisterCallbacksOnTarget()
- {
- RegisterCallback(OnMouseDown);
- RegisterCallback(OnMouseMove);
- RegisterCallback(OnMouseUp);
- }
-
- protected void UnregisterCallbacksFromTarget()
- {
- UnregisterCallback(OnMouseDown);
- UnregisterCallback(OnMouseMove);
- UnregisterCallback(OnMouseUp);
- }
-
- bool m_Dragging;
-
- int m_DraggingDirection;
-
- int draggingDirection
- {
- get => m_DraggingDirection;
- set
- {
- if (m_DraggingDirection == value)
- {
- return;
- }
-
- m_DraggingDirection = value;
- EnableInClassList("dragging--left", m_DraggingDirection < 0);
- EnableInClassList("dragging--right", m_DraggingDirection > 0);
- }
- }
-
- public bool dragging
- {
- get => m_Dragging;
- set
- {
- if (m_Dragging == value)
- {
- return;
- }
-
- m_Dragging = value;
- animated = !m_Dragging;
- EnableInClassList("dragged", m_Dragging);
-
- if (value)
- {
- cardListView.StartDragging(this);
- }
- else
- {
- cardListView.FinishDragging(this);
- Unselect();
- }
-
- cardListView.DoLayout();
- }
- }
-
- public void OnDrop(int oldIndex, int newIndex)
- {
- dropped?.Invoke(oldIndex, newIndex);
- }
-
- protected void OnMouseDown(MouseDownEvent e)
- {
- if (!cardListView.canPlayCards || m_Active)
- {
- e.StopImmediatePropagation();
- return;
- }
-
- if (panel?.GetCapturingElement(PointerId.mousePointerId) != null)
- {
- return;
- }
-
- if (e.button == (int)MouseButton.LeftMouse)
- {
- m_Start = e.localMousePosition;
-
- m_Active = true;
-
- // style.backgroundColor = Color.red;
- this.CaptureMouse();
- e.StopPropagation();
- }
- }
-
- protected void OnMouseMove(MouseMoveEvent e)
- {
- if (m_Active)
- {
- // Ensure the card is selected when we start dragging it.
- Select();
-
- var diff = e.localMousePosition - m_Start;
-
- if (!dragging && Math.Abs(diff.x) > 5)
- {
- dragging = true;
- return;
- }
-
- if (!dragging)
- {
- return;
- }
-
- var targetScale = transform.scale;
- diff.x *= targetScale.x;
- diff.y *= targetScale.y;
-
- var rect = CalculatePosition(layout.x + diff.x, layout.y + diff.y, layout.width, layout.height);
-
- /*if (this.isLayoutManual)
- {
- target.layout = rect;
- }
- else if (target.resolvedStyle.position == Position.Absolute)
- {*/
-
- var oldLeft = style.left.value.value;
- style.left = rect.x;
- draggingDirection = oldLeft < style.left.value.value ? -1 : 1;
-
- // this.style.top = rect.y;
- // }
-
- cardListView.Drag(this);
- e.StopPropagation();
- }
- }
-
- protected void OnMouseUp(MouseUpEvent e)
- {
- if (m_Active)
- {
- if (e.button == (int)MouseButton.LeftMouse)
- {
- // Select or unselect the card if we didn't drag it.
- if (!m_Dragging)
- {
- if (selected)
- {
- Unselect();
- }
- else
- {
- Select();
- }
- }
- m_Active = false;
- dragging = false;
-
- // style.backgroundColor = Color.white;
-
- this.ReleaseMouse();
- e.StopPropagation();
- }
- }
- }
-
- public bool MoveLeft(int count = 1)
- {
- if (parent == null)
- {
- return false;
- }
-
- if (parent.IndexOf(this) - count < 0)
- {
- return false;
- }
-
- MoveToIndex(parent.IndexOf(this) - count);
-
- return true;
- }
-
- public bool MoveRight(int count = 1)
- {
- if (parent == null)
- {
- return false;
- }
-
- if (parent.IndexOf(this) + count >= parent.childCount)
- {
- return false;
- }
-
- MoveToIndex(parent.IndexOf(this) + count);
-
- return true;
- }
-
- void MoveToIndex(int index)
- {
- var oldIndex = parent.IndexOf(this);
-
- if (index == parent.childCount - 1)
- {
- PlaceInFront(parent[index]);
- }
- else
- {
- if (index < oldIndex)
- {
- PlaceBehind(parent[index]);
- }
- else
- {
- PlaceInFront(parent[index]);
- }
- }
-
- cardListView.DoLayout();
- dropped?.Invoke(oldIndex, index);
- }
- }
-
- [UxmlElement]
- partial class CardListView : VisualElement
- {
- static public int defaultCardSize = 208;
- static public float s_FontScale = 1.0f;
- static public int cardSize = 208;
-
- public float fontScale
- {
- get => s_FontScale;
- set
- {
- s_FontScale = value;
- style.fontSize = value * 130;
- cardSize = (int)(defaultCardSize * value);
- }
- }
-
- public int spacing = 30;
- VisualElement m_InsertionPlaceholder;
-
- public bool canPlayCards { get; set; }
-
- public CardListView()
- {
- m_InsertionPlaceholder = new VisualElement();
- m_InsertionPlaceholder.AddToClassList("lsp-card-view-item");
- m_InsertionPlaceholder.AddToClassList("lsp-insertion-placeholder");
- // m_InsertionPlaceholder.style.backgroundColor = new Color(0, 0, 1, 0.5f);
-
- RegisterCallbacksOnTarget();
- }
-
- void ComputeInsertionIndex(UITkLetterCard card)
- {
- var newIndex = 0;
- var cc = childCount;
- var i = 0;
-
- foreach (var child in Children())
- {
- // Do not lay out the card being dragged.
- if (child is UITkLetterCard { dragging: true })
- {
- cc--;
- break;
- }
- }
-
- var startX = (layout.width - (cc * cardSize + (cc + 1) * spacing)) / 2;
-
- foreach (var child in Children())
- {
- // Do not lay out the card being dragged.
- if (card == child)
- {
- continue;
- }
-
- var r = new Rect
- {
- xMin = startX + i * cardSize + (i + 1) * spacing,
- width = cardSize,
- height = cardSize,
- yMin = (layout.height - cardSize) / 2
- };
-
- if (card.layout.center.x > r.xMax)
- {
- newIndex++;
- }
-
- i++;
- }
-
- insertionIndex = Math.Clamp(newIndex, 0, cc - 1);
- }
-
- int m_InsertionIndex = -1;
-
- int insertionIndex
- {
- get => m_InsertionIndex;
- set
- {
- if (m_InsertionIndex == value)
- {
- return;
- }
-
- m_InsertionIndex = value;
- MoveToIndex(m_InsertionPlaceholder, value);
- }
- }
-
- void MoveToIndex(VisualElement ve, int index)
- {
- var currentIndex = ve.parent.IndexOf(ve);
-
- if (index == childCount - 1)
- {
-
- ve.PlaceInFront(this[index]);
- }
- else
- {
- if (index < currentIndex)
- {
- ve.PlaceBehind(this[index]);
- }
- else
- {
- ve.PlaceInFront(this[index]);
- }
- }
-
- DoLayout();
- }
-
- void OnGeometryChanged(GeometryChangedEvent e)
- {
- DoLayout();
- }
-
- int m_StartIndex;
-
- public void StartDragging(UITkLetterCard card)
- {
- m_StartIndex = IndexOf(card);
- // style.position = Position.Absolute;
- card.PlaceInFront(Children().Last());
- Insert(m_StartIndex, m_InsertionPlaceholder);
- ComputeInsertionIndex(card);
- DoLayout();
-
- schedule.Execute(() =>
- {
- m_InsertionPlaceholder.AddToClassList("animated");
- }).ExecuteLater(400);
- }
-
- public void FinishDragging(UITkLetterCard card)
- {
- m_InsertionPlaceholder.RemoveFromClassList("animated");
- m_InsertionPlaceholder.RemoveFromHierarchy();
- var newIndex = m_InsertionIndex;
-
- if (newIndex == childCount - 1)
- {
- card.PlaceInFront(this[newIndex - 1]);
- }
- else
- {
- card.PlaceBehind(this[newIndex]);
- }
-
- card.OnDrop(m_StartIndex, newIndex);
- DoLayout();
- }
-
- public void Drag(UITkLetterCard card)
- {
- ComputeInsertionIndex(card);
- }
-
- public void DoLayout()
- {
- var i = 0;
-
- var cc = childCount;
-
- foreach (var child in Children())
- {
- // Do not lay out the card being dragged.
- if (child is UITkLetterCard { dragging: true })
- {
- cc--;
- break;
- }
- }
-
- var startX = (layout.width - (cc * cardSize + (cc + 1) * spacing)) / 2;
-
- foreach (var child in Children())
- {
- // Do not lay out the card being dragged.
- if (child is UITkLetterCard { dragging: true })
- {
- continue;
- }
-
- child.style.left = startX + i * cardSize + (i + 1) * spacing;
- child.style.width = cardSize;
- child.style.height = cardSize;
- child.style.top = 0; // DON'T CENTER ANYMORE, (layout.height - cardSize) / 2;
- i++;
- }
- }
-
- protected void RegisterCallbacksOnTarget()
- {
- RegisterCallback(OnMouseDown);
- RegisterCallback(OnMouseMove);
- RegisterCallback(OnMouseUp);
- RegisterCallback(OnGeometryChanged);
- }
-
- bool m_Active;
- Vector2 m_Start;
- bool m_Dragging;
- bool m_SwipeLeft;
-
- UITkLetterCard m_SelectedCard;
-
- public UITkLetterCard selectedCard
- {
- get => m_SelectedCard;
- set
- {
- if (m_SelectedCard == value)
- {
- return;
- }
-
- if (m_SelectedCard != null)
- {
- m_SelectedCard.selected = false;
- }
-
- m_SelectedCard = value;
-
- if (m_SelectedCard != null)
- {
- m_SelectedCard.selected = true;
- }
- }
- }
-
- void OnMouseDown(MouseDownEvent e)
- {
- m_Active = true;
- m_Start = e.localMousePosition;
- }
-
- void OnMouseMove(MouseMoveEvent e)
- {
- if (m_Active)
- {
- var diff = e.localMousePosition - m_Start;
- m_SwipeLeft = diff.x < 0;
-
- if (!m_Dragging && Math.Abs(diff.x) > 5)
- {
- m_Dragging = true;
- }
- }
- }
-
- void OnMouseUp(MouseUpEvent e)
- {
- if (m_Dragging)
- {
- if (m_SwipeLeft)
- {
- OnSwipeLeft();
- }
- else
- {
- OnSwipeRight();
- }
- }
-
- m_Active = true;
- m_Dragging = true;
- }
-
- public void OnSwipeLeft()
- {
- MoveCard(true);
- }
-
- public void OnSwipeRight()
- {
- MoveCard(false);
- }
-
- void MoveCard(bool shouldMoveLeft)
- {
- var draggable = m_SelectedCard;
-
- if (draggable == null)
- {
- return;
- }
-
- // var accElement = draggable.transform.GetComponent();
-
- if (shouldMoveLeft ? draggable.MoveLeft() : draggable.MoveRight())
- {
- var index = IndexOf(draggable);
- var otherSiblingIndex = shouldMoveLeft ? index + 1 : index - 1;
- var otherSibling = this[otherSiblingIndex];
-
- // Announce that the card was moved.
- var localizedString = new LocalizedString
- {
- TableReference = "Game Text",
- TableEntryReference = "ANNOUNCEMENT_CARD_MOVED"
- };
-
- var selectedLetter = new StringVariable
- {
- Value = draggable.name
- };
-
- var moveLeft = new BoolVariable
- {
- Value = shouldMoveLeft
- };
-
- var otherLetter = new StringVariable
- {
- Value = otherSibling.name
- };
-
- localizedString.Add("selectedLetter", selectedLetter);
- localizedString.Add("shouldMoveLeft", moveLeft);
- localizedString.Add("otherLetter", otherLetter);
-
- localizedString.StringChanged += announcement =>
- AssistiveSupport.notificationDispatcher.SendAnnouncement(announcement);
-
- // AssistiveSupport.defaultHierarchy.MoveNode(accElement.node, accElement.node.parent,
- // accElement.transform.GetSiblingIndex());
-
- // // Only refresh the frames for now to leave the announcement request to be handled.
- // this.ManualRectRefresh();
-
- // AssistiveSupport.notificationDispatcher.SendLayoutChanged(accElement.node);
- // this.schedule.Execute(()=>AssistiveSupport.notificationDispatcher.SendLayoutChanged()).ExecuteLater(500);
- }
- }
-
- protected void UnregisterCallbacksFromTarget()
- {
- UnregisterCallback(OnMouseDown);
- UnregisterCallback(OnMouseMove);
- UnregisterCallback(OnMouseUp);
- }
- }
-}
diff --git a/Assets/Scripts/UITk/Controls/ButtonStripField.cs b/Assets/Scripts/UITk/Controls/ButtonStripField.cs
index ac47fcb..23b00b9 100644
--- a/Assets/Scripts/UITk/Controls/ButtonStripField.cs
+++ b/Assets/Scripts/UITk/Controls/ButtonStripField.cs
@@ -1,7 +1,6 @@
using System.Collections.Generic;
using Unity.Properties;
using Unity.Samples.ScreenReader;
-using UnityEngine;
using UnityEngine.UIElements;
namespace Unity.Samples.LetterSpell
diff --git a/Assets/Scripts/UITk/Controls/Popup.cs b/Assets/Scripts/UITk/Controls/Popup.cs
index d172931..f108b1f 100644
--- a/Assets/Scripts/UITk/Controls/Popup.cs
+++ b/Assets/Scripts/UITk/Controls/Popup.cs
@@ -47,9 +47,6 @@ public PopupOverlay()
m_ContentContainer.GetOrCreateAccessibleProperties().modal = true;
hierarchy.Add(m_ContentContainer);
- var styleSheet = Resources.Load("UITk/Themes/LetterSpellTheme");
- styleSheets.Add(styleSheet);
-
RegisterCallback(OnPointerDown);
}
diff --git a/Assets/Scripts/UITk/Controls/StackView.cs b/Assets/Scripts/UITk/Controls/StackView.cs
index 8e9d354..47f7d4c 100644
--- a/Assets/Scripts/UITk/Controls/StackView.cs
+++ b/Assets/Scripts/UITk/Controls/StackView.cs
@@ -14,7 +14,6 @@ public partial class StackView : VisualElement
public override VisualElement contentContainer => m_ContentContainer;
-
[UxmlAttribute]
public int index
{
diff --git a/Assets/Scripts/UITk/LetterCardView.cs b/Assets/Scripts/UITk/LetterCardView.cs
new file mode 100644
index 0000000..7d4db01
--- /dev/null
+++ b/Assets/Scripts/UITk/LetterCardView.cs
@@ -0,0 +1,672 @@
+using System;
+using System.Linq;
+using Unity.Properties;
+using UnityEngine;
+using UnityEngine.Accessibility;
+using UnityEngine.Localization;
+using UnityEngine.Localization.SmartFormat.PersistentVariables;
+using UnityEngine.UIElements;
+
+namespace Unity.Samples.LetterSpell
+{
+ ///
+ /// This class represents the view of letter cards.
+ ///
+ [UxmlElement]
+ public partial class LetterCardView : VisualElement
+ {
+ internal static readonly BindingId itemSizeProperty = nameof(itemSize);
+ internal static readonly BindingId itemSpacingProperty = nameof(itemSpacing);
+ internal static readonly BindingId lettersProperty = nameof(letters);
+ //internal static readonly BindingId reorderedLettersProperty = nameof(reorderedLetters);
+
+ ///
+ /// USS class name of the letter card view.
+ ///
+ public static readonly string ussClassName = "lsp-letter-card-view";
+
+ ///
+ /// USS class name of the letter card view.
+ ///
+ public static readonly string animatedUssClassName = ussClassName + "--animated";
+
+ ///
+ /// USS class name of an item in the letter card view.
+ ///
+ public static readonly string itemUssClassName = ussClassName + "__item";
+
+ ///
+ /// USS class name of a selected item in the letter card view.
+ ///
+ public static readonly string selectedItemUssClassName = itemUssClassName + "--selected";
+
+ ///
+ /// USS class name of a focused item in the letter card view.
+ ///
+ public static readonly string focusItemUssClassName = itemUssClassName + "--focused";
+
+ ///
+ /// USS class name of a dragged item in the letter card view.
+ ///
+ public static readonly string draggedItemUssClassName = itemUssClassName + "--dragged";
+
+ ///
+ /// USS class name of a dragged item that is being moved to the left in the letter card view.
+ ///
+ public static readonly string draggedLeftItemUssClassName = itemUssClassName + "--dragged-left";
+
+ ///
+ /// USS class name of a dragged item that is being moved to the right in the letter card view.
+ ///
+ public static readonly string draggedRightItemUssClassName = itemUssClassName + "--dragged-right";
+
+ ///
+ /// USS class name of an animated item in the letter card view.
+ ///
+ public static readonly string animatedItemUssClassName = itemUssClassName + "--animated";
+
+ ///
+ /// USS class name of the insertion placeholder item in the letter card view.
+ ///
+ public static readonly string insertionPlaceholderItemUssClassName = ussClassName + "__insertion-placeholder-item";
+
+ static CustomStyleProperty s_ItemSizeProperty = new("--item-size");
+ static CustomStyleProperty s_ItemSpacingProperty = new("--item-spacing");
+
+ const int kDefaultItemSize = 208;
+ const int k_DefaultItemSpacing = 30;
+ static public int cardSize = 208;
+
+ float m_ItemSize = kDefaultItemSize;
+ float m_ItemSpacing = k_DefaultItemSpacing;
+ bool m_ItemSizeIsSetInline;
+ bool m_ItemSpacingIsSetInline;
+
+ VisualElement m_InsertionPlaceholder;
+ LetterCardViewItem m_SelectedCard;
+
+ private char[] m_Letters;
+
+ bool m_Animated;
+
+ // Interaction
+ int m_StartIndex;
+ int m_InsertionIndex = -1;
+ bool m_Active;
+ Vector2 m_StartMousePos;
+ bool m_Dragging;
+ bool m_SwipeLeft;
+
+ ///
+ /// The size of each item in the letter card view.
+ ///
+ [CreateProperty]
+ public float itemSize
+ {
+ get => m_ItemSize;
+ set
+ {
+ if (Mathf.Approximately(m_ItemSize, value))
+ return;
+
+ m_ItemSizeIsSetInline = true;
+ m_ItemSize = value;
+ NotifyPropertyChanged(itemSizeProperty);
+ }
+ }
+
+ ///
+ /// The spacing between items in the letter card view.
+ ///
+ [CreateProperty]
+ public float itemSpacing
+ {
+ get => m_ItemSpacing;
+ set
+ {
+ if (Mathf.Approximately(m_ItemSpacing, value))
+ return;
+
+ m_ItemSpacingIsSetInline = true;
+ m_ItemSpacing = value;
+ NotifyPropertyChanged(itemSpacingProperty);
+ }
+ }
+
+ ///
+ /// The selected item in the letter card view.
+ ///
+ public LetterCardViewItem selectedCard
+ {
+ get => m_SelectedCard;
+ set
+ {
+ if (m_SelectedCard == value)
+ {
+ return;
+ }
+
+ if (m_SelectedCard != null)
+ m_SelectedCard.selected = false;
+
+ m_SelectedCard = value;
+
+ if (m_SelectedCard != null)
+ m_SelectedCard.selected = true;
+ }
+ }
+
+ ///
+ /// Indicates whether the user can interact with the letter cards.
+ ///
+ public bool interactable { get; set; } = true;
+
+ ///
+ /// The view model of letter cards.
+ ///
+ [CreateProperty, UxmlAttribute]
+ public char[] letters
+ {
+ get => m_Letters;
+ set
+ {
+ if (m_Letters == value)
+ return;
+
+ m_Letters = value;
+ NotifyLettersChanged();
+ RebuildItems();
+ }
+ }
+
+ void NotifyLettersChanged()
+ {
+ NotifyPropertyChanged(lettersProperty);
+ lettersChanged?.Invoke(this);
+ }
+
+ ///
+ /// Indicates whether the letter cards should animate when they change position.
+ ///
+ bool animated
+ {
+ get => m_Animated;
+ set
+ {
+ if (m_Animated == value)
+ {
+ return;
+ }
+
+ m_Animated = value;
+ EnableInClassList(animatedUssClassName, animated);
+ }
+ }
+
+ ///
+ /// The index where the dragged card will be inserted once dropped.
+ ///
+ int insertionIndex
+ {
+ get => m_InsertionIndex;
+ set
+ {
+ if (m_InsertionIndex == value)
+ {
+ return;
+ }
+
+ m_InsertionIndex = value;
+ MoveToIndex(m_InsertionPlaceholder, value);
+ }
+ }
+
+ ///
+ /// Event sent when a letter card is reordered.
+ ///
+ public event Action letterReordered;
+
+ ///
+ /// Event sent when the letters property changes.
+ ///
+ public event Action lettersChanged;
+
+ ///
+ /// Constructs a letter card view.
+ ///
+ public LetterCardView()
+ {
+ AddToClassList(ussClassName);
+
+ m_InsertionPlaceholder = new VisualElement();
+ m_InsertionPlaceholder.AddToClassList(insertionPlaceholderItemUssClassName);
+
+ RegisterCallback(OnMouseDown);
+ RegisterCallback(OnMouseMove);
+ RegisterCallback(OnMouseUp);
+ RegisterCallback(OnGeometryChanged);
+ RegisterCallback(OnCustomStyleResolved);
+ }
+
+ void OnCustomStyleResolved(CustomStyleResolvedEvent e)
+ {
+ ReadCustomProperties(e.customStyle);
+ }
+
+ void ReadCustomProperties(ICustomStyle customStyleProvider)
+ {
+ if (!m_ItemSizeIsSetInline)
+ {
+ if (customStyleProvider.TryGetValue(s_ItemSizeProperty, out var itemSize))
+ {
+ m_ItemSize = itemSize;
+ }
+ else
+ {
+ m_ItemSize = kDefaultItemSize;
+ }
+ }
+
+ if (!m_ItemSpacingIsSetInline)
+ {
+ if (customStyleProvider.TryGetValue(s_ItemSpacingProperty, out var itemSpacing))
+ {
+ m_ItemSpacing = itemSpacing;
+ }
+ else
+ {
+ m_ItemSpacing = k_DefaultItemSpacing;
+ }
+ }
+ }
+
+ ///
+ /// Regenerates all the letter cards.
+ ///
+ void RebuildItems()
+ {
+ selectedCard = null;
+ //accessibilityFocusedCard = null;
+
+ // Remove all cards.
+ Clear();
+
+ // Generate new card items.
+ foreach (var letter in letters)
+ {
+ var cardItem = new LetterCardViewItem(letter);
+ Add(cardItem);
+ cardItem.dropped += (oldIndex, newIndex) => { letterReordered?.Invoke(this, oldIndex, newIndex); };
+ }
+ }
+
+ void ComputeInsertionIndex(LetterCardViewItem card)
+ {
+ var newIndex = 0;
+ var cc = childCount;
+ var i = 0;
+
+ foreach (var child in Children())
+ {
+ // Do not lay out the card being dragged.
+ if (child is LetterCardViewItem { dragged: true })
+ {
+ cc--;
+ break;
+ }
+ }
+
+ var startX = (layout.width - (cc * cardSize + (cc + 1) * itemSpacing)) / 2;
+
+ foreach (var child in Children())
+ {
+ // Do not lay out the card being dragged.
+ if (card == child)
+ {
+ continue;
+ }
+
+ var r = new Rect();
+ r.xMin = startX + i * cardSize + (i + 1) * itemSpacing;
+ r.width = cardSize;
+ r.height = cardSize;
+ r.yMin = (layout.height - cardSize)/2;
+
+ if (card.layout.center.x > r.xMax)
+ {
+ newIndex++;
+ }
+
+ i++;
+ }
+
+ insertionIndex = Math.Clamp(newIndex, 0, cc - 1);
+ }
+
+ void MoveToIndex(VisualElement ve, int index)
+ {
+ var currentIndex = ve.parent.IndexOf(ve);
+
+ if (index == childCount - 1)
+ {
+
+ ve.PlaceInFront(this[index]);
+ }
+ else
+ {
+ if (index < currentIndex)
+ {
+ ve.PlaceBehind(this[index]);
+ }
+ else
+ {
+ ve.PlaceInFront(this[index]);
+ }
+ }
+
+ DoLayout();
+ }
+
+ void OnGeometryChanged(GeometryChangedEvent e)
+ {
+ DoLayout();
+ }
+
+ public void StartDragging(LetterCardViewItem card)
+ {
+ m_StartIndex = IndexOf(card);
+ card.PlaceInFront(Children().Last());
+ Insert(m_StartIndex, m_InsertionPlaceholder);
+ ComputeInsertionIndex(card);
+ DoLayout();
+
+ schedule.Execute(() =>
+ {
+ m_InsertionPlaceholder.AddToClassList(animatedItemUssClassName);
+ }).ExecuteLater(400);
+ }
+
+ public void FinishDragging(LetterCardViewItem card)
+ {
+ m_InsertionPlaceholder.RemoveFromClassList(animatedItemUssClassName);
+ m_InsertionPlaceholder.RemoveFromHierarchy();
+ var newIndex = m_InsertionIndex;
+
+ if (newIndex == childCount - 1)
+ {
+ card.PlaceInFront(this[newIndex - 1]);
+ }
+ else
+ {
+ card.PlaceBehind(this[newIndex]);
+ }
+
+ MoveData(m_StartIndex, newIndex);
+ card.OnDrop(m_StartIndex, newIndex);
+ DoLayout();
+ }
+
+ public void Drag(LetterCardViewItem card)
+ {
+ ComputeInsertionIndex(card);
+ }
+
+ public void DoLayout()
+ {
+ var i = 0;
+ var cc = childCount;
+
+ foreach (var child in Children())
+ {
+ // Do not lay out the card being dragged.
+ if (child is LetterCardViewItem { dragged: true })
+ {
+ cc--;
+ break;
+ }
+ }
+
+ var startX = (layout.width - (cc * cardSize + (cc + 1) * itemSpacing)) / 2;
+
+ foreach (var child in Children())
+ {
+ // Do not lay out the card being dragged.
+ if (child is LetterCardViewItem { dragged: true })
+ {
+ continue;
+ }
+
+ child.style.left = startX + i * cardSize + (i + 1) * itemSpacing;
+ child.style.width = cardSize;
+ child.style.height = cardSize;
+ child.style.top = 0;
+ i++;
+ }
+ }
+
+ void OnMouseDown(MouseDownEvent e)
+ {
+ m_Active = true;
+ m_StartMousePos = e.localMousePosition;
+ }
+
+ void OnMouseMove(MouseMoveEvent e)
+ {
+ if (m_Active)
+ {
+ var diff = e.localMousePosition - m_StartMousePos;
+ m_SwipeLeft = diff.x < 0;
+
+ if (!m_Dragging && Math.Abs(diff.x) > 5)
+ {
+ m_Dragging = true;
+ }
+ }
+ }
+
+ void OnMouseUp(MouseUpEvent e)
+ {
+ if (m_Dragging)
+ {
+ if (m_SwipeLeft)
+ {
+ OnSwipeLeft();
+ }
+ else
+ {
+ OnSwipeRight();
+ }
+ }
+
+ m_Active = true;
+ m_Dragging = true;
+ }
+
+ void OnSwipeLeft()
+ {
+ MoveSelectedCardLeft();
+ }
+
+ void OnSwipeRight()
+ {
+ MoveSelectedCardRight();
+ }
+
+ ///
+ /// Moves the selected card to the left by the specified count.
+ ///
+ /// The amount of steps the card should move
+ /// True if the card was successfully moved
+ public bool MoveSelectedCardLeft(int count = 1)
+ {
+ return MoveSelectedCard(true, count);
+ }
+
+ ///
+ /// Moves the selected card to the right by the specified count.
+ ///
+ /// The amount of steps the card should move
+ /// True if the card was successfully moved
+ public bool MoveSelectedCardRight(int count = 1)
+ {
+ return MoveSelectedCard(false, count);
+ }
+
+ ///
+ /// Moves the selected card to the left or right by the specified count.
+ /// If no card is selected, it will not move and return false.
+ /// If the selected card is already at the leftmost or rightmost position, it will not move and return false.
+ /// If the card is successfully moved, it will return true.
+ ///
+ /// Indicate whther the card should be left or right
+ /// The amount of steps by which the selected card should be moved
+ /// True if the card was successfully moved
+ public bool MoveSelectedCard(bool shouldMoveLeft, int count = 1)
+ {
+ var draggable = m_SelectedCard;
+
+ if (draggable == null)
+ {
+ return false;
+ }
+
+ var selectedCardText = m_SelectedCard.letter.ToString();
+
+ if (shouldMoveLeft ? MoveCardLeft(draggable, count) : MoveCardRight(draggable, count))
+ {
+ var index = IndexOf(draggable);
+ var otherSiblingIndex = shouldMoveLeft ? index + count : index - count;
+ var otherSibling = this[otherSiblingIndex] as LetterCardViewItem;
+ var otherCardText = otherSibling.letter.ToString();
+
+ // Announce that the card was moved.
+ var localizedString = new LocalizedString
+ {
+ TableReference = "Game Text",
+ TableEntryReference = "ANNOUNCEMENT_CARD_MOVED"
+ };
+
+ var selectedLetter = new StringVariable
+ {
+ Value = selectedCardText
+ };
+
+ var moveLeft = new BoolVariable
+ {
+ Value = shouldMoveLeft
+ };
+
+ var otherLetter = new StringVariable
+ {
+ Value = otherCardText
+ };
+
+ localizedString.Add("selectedLetter", selectedLetter);
+ localizedString.Add("shouldMoveLeft", moveLeft);
+ localizedString.Add("otherLetter", otherLetter);
+
+ // Give a bit of time for the layout change notification to be processed first so that the announcement
+ // is not interrupted by the focus change.
+ schedule.Execute(() =>
+ {
+ localizedString.StringChanged += announcement =>
+ AssistiveSupport.notificationDispatcher.SendAnnouncement(announcement);
+ }).ExecuteLater(200);
+ return true;
+ }
+
+ return false;
+ }
+
+ ///
+ /// Moves the specified card to the left by the specified count.
+ /// If the card is already at the leftmost position, it will not move and return false.
+ /// If the card is not part of a LetterCardView, it will not move and return false.
+ /// If the card is successfully moved, it will return true.
+ ///
+ /// The card to move
+ /// The amount of steps the card should move
+ /// Returns true if the card was moved
+ public bool MoveCardLeft(LetterCardViewItem card, int count = 1)
+ {
+ if (IndexOf(card) - count < 0)
+ {
+ return false;
+ }
+
+ MoveToIndex(card, IndexOf(card) - count);
+
+ return true;
+ }
+
+ ///
+ /// Moves the specified card to the right by the specified count.
+ /// If the card is already at the rightmost position, it will not move and return false.
+ /// If the card is not part of a LetterCardView, it will not move and return false.
+ /// If the card is successfully moved, it will return true.
+ ///
+ /// The card to move
+ /// The amount of steps the card should move
+ /// Returns true if the card was moved
+ public bool MoveCardRight(LetterCardViewItem card, int count = 1)
+ {
+ if (parent.IndexOf(this) + count >= parent.childCount)
+ {
+ return false;
+ }
+
+ MoveToIndex(card, IndexOf(card) + count);
+
+ return true;
+ }
+
+ void MoveToIndex(LetterCardViewItem card, int index)
+ {
+ var oldIndex = IndexOf(card);
+
+ MoveData(oldIndex, index);
+
+ if (index == childCount - 1)
+ {
+ card.PlaceInFront(this[index]);
+ }
+ else
+ {
+ if (index < oldIndex)
+ {
+ card.PlaceBehind(this[index]);
+ }
+ else
+ {
+ card.PlaceInFront(this[index]);
+ }
+ }
+ DoLayout();
+ card.OnDrop(oldIndex, index);
+ }
+
+ void MoveData(int oldIndex, int newIndex)
+ {
+ if (m_Letters == null || oldIndex < 0 || oldIndex >= m_Letters.Length || newIndex < 0 || newIndex >= m_Letters.Length)
+ {
+ return;
+ }
+
+ // Move the letter in-place in the char array without copying the entire array and
+ // just moving data.
+ var letter = m_Letters[oldIndex];
+
+ if (oldIndex < newIndex)
+ {
+ Array.Copy(m_Letters, oldIndex + 1, m_Letters, oldIndex, newIndex - oldIndex);
+ }
+ else if (oldIndex > newIndex)
+ {
+ Array.Copy(m_Letters, newIndex, m_Letters, newIndex + 1, oldIndex - newIndex);
+ }
+ m_Letters[newIndex] = letter;
+
+ NotifyLettersChanged();
+ }
+ }
+}
diff --git a/Assets/Scripts/UITk/LetterCardView.cs.meta b/Assets/Scripts/UITk/LetterCardView.cs.meta
new file mode 100644
index 0000000..b99d79b
--- /dev/null
+++ b/Assets/Scripts/UITk/LetterCardView.cs.meta
@@ -0,0 +1,2 @@
+fileFormatVersion: 2
+guid: 454112892073445a6aba6ad33828e43b
\ No newline at end of file
diff --git a/Assets/Scripts/UITk/LetterCardViewItem.cs b/Assets/Scripts/UITk/LetterCardViewItem.cs
new file mode 100644
index 0000000..9f163a5
--- /dev/null
+++ b/Assets/Scripts/UITk/LetterCardViewItem.cs
@@ -0,0 +1,345 @@
+using System;
+using System.Globalization;
+using System.Linq;
+using Unity.Properties;
+using UnityEngine;
+using UnityEngine.Accessibility;
+using UnityEngine.Scripting;
+using UnityEngine.UIElements;
+using Unity.Samples.ScreenReader;
+using UnityEditor;
+using UnityEngine.Localization.Settings;
+using Button = UnityEngine.UIElements.Button;
+
+namespace Unity.Samples.LetterSpell
+{
+ ///
+ /// This class represents a card in LetterSpell
+ ///
+ [UxmlElement]
+ public partial class LetterCardViewItem : AccessibleVisualElement
+ {
+ internal static readonly BindingId selectedProperty = nameof(selected);
+ internal static readonly BindingId focusedProperty = nameof(focused);
+ internal static readonly BindingId draggingProperty = nameof(dragged);
+
+ Label m_LetterLabel;
+ Vector2 m_StartMousePos;
+ bool m_Active;
+ bool m_Selected;
+ bool m_Dragged;
+ int m_DraggingDirection;
+ char m_Letter;
+
+ ///
+ /// The Card view that contains this card.
+ ///
+ LetterCardView cardView => parent as LetterCardView;
+
+ ///
+ /// Indicates whether this card is selected.
+ ///
+ [CreateProperty(ReadOnly = true)]
+ public bool selected
+ {
+ get => m_Selected;
+ internal set
+ {
+ if (m_Selected == value)
+ return;
+ m_Selected = value;
+ if (value)
+ Focus();
+ UpdateStyleClasses();
+ NotifyPropertyChanged(selectedProperty);
+ }
+ }
+
+ ///
+ /// Indicates whether this card has focus
+ ///
+ [CreateProperty]
+ bool focused => focusController?.focusedElement == this;
+
+ ///
+ /// Idicates whether this card is being dragged.
+ ///
+ [CreateProperty, UxmlAttribute]
+ public bool dragged
+ {
+ get => m_Dragged;
+ private set
+ {
+ if (m_Dragged == value)
+ {
+ return;
+ }
+
+ m_Dragged = value;
+
+ if (cardView != null)
+ {
+ if (value)
+ {
+ cardView.StartDragging(this);
+ }
+ else
+ {
+ cardView.FinishDragging(this);
+ Deselect();
+ }
+
+ cardView.DoLayout();
+ }
+
+ UpdateStyleClasses();
+ NotifyPropertyChanged(draggingProperty);
+ }
+ }
+
+ ///
+ /// The direction the card is being dragged. Negative values indicate left, positive values indicate right.
+ ///
+ [CreateProperty, UxmlAttribute]
+ public int draggingDirection
+ {
+ get => m_DraggingDirection;
+ set
+ {
+ if (m_DraggingDirection == value)
+ {
+ return;
+ }
+
+ m_DraggingDirection = value;
+ UpdateStyleClasses();
+ }
+ }
+
+ ///
+ /// The letter displayed by the card
+ ///
+ [CreateProperty, UxmlAttribute]
+ public char letter
+ {
+ get => m_Letter;
+ set
+ {
+ if (m_Letter == value)
+ return;
+ m_Letter = value;
+ UpdateLabel();
+ }
+ }
+
+ ///
+ /// Event sent when the card is droppped.
+ ///
+ public event Action dropped;
+
+ ///
+ /// Default constructor.
+ ///
+ public LetterCardViewItem() : this('\0')
+ {
+ }
+
+ ///
+ /// Constructs a visual card with a letter.
+ ///
+ public LetterCardViewItem(char letter)
+ {
+ AddToClassList(LetterCardView.itemUssClassName);
+
+ // Make it focusable.
+ focusable = true;
+
+ m_LetterLabel = new Label();
+ m_LetterLabel.GetOrCreateAccessibleProperties().ignored = true;
+
+ Add(m_LetterLabel);
+
+ style.position = Position.Absolute;
+
+ RegisterCallback(OnMouseDown);
+ RegisterCallback(OnMouseMove);
+ RegisterCallback(OnMouseUp);
+ RegisterCallback(OnAttachToPanel);
+
+ this.letter = letter;
+
+ accessible.hint = LocalizationSettings.StringDatabase.GetLocalizedString("Game Text", "LETTER_CARD_HINT_UNSELECTED");
+ accessible.selected += () =>
+ {
+ if (!selected)
+ {
+ Select();
+ }
+ else
+ {
+ Deselect();
+ }
+
+ return true;
+ };
+ }
+
+ void UpdateLabel()
+ {
+ if (m_LetterLabel == null)
+ return;
+
+ var cultureInfo = LocalizationSettings.SelectedLocale?.Identifier.CultureInfo ?? CultureInfo.CurrentUICulture;
+ var localizedText = letter.ToString();
+
+ m_LetterLabel.text = localizedText.ToUpper(cultureInfo);
+ accessible.label = localizedText;
+ }
+
+ ///
+ /// Selects this card.
+ ///
+ public void Select()
+ {
+ if (cardView == null || selected)
+ return;
+
+ if (cardView.selectedCard != this)
+ {
+ cardView.selectedCard = this;
+
+ accessible.hint = LocalizationSettings.StringDatabase.GetLocalizedString("Game Text", "LETTER_CARD_HINT_SELECTED");
+ }
+ }
+
+ ///
+ /// Unseletec this card if it is selected.
+ ///
+ public void Deselect()
+ {
+ if (cardView == null || !selected)
+ return;
+
+ // Check whether the card is focused or not.
+ cardView.selectedCard = null;
+
+ accessible.hint = LocalizationSettings.StringDatabase.GetLocalizedString("Game Text", "LETTER_CARD_HINT_UNSELECTED");
+ }
+
+ void OnAttachToPanel(AttachToPanelEvent e)
+ {
+ cardView.DoLayout();
+ }
+
+ void UpdateStyleClasses()
+ {
+ EnableInClassList(LetterCardView.selectedItemUssClassName, selected);
+ EnableInClassList(LetterCardView.draggedItemUssClassName, m_Dragged);
+ EnableInClassList(LetterCardView.draggedLeftItemUssClassName, m_Dragged && m_DraggingDirection < 0);
+ EnableInClassList(LetterCardView.draggedRightItemUssClassName, m_Dragged && m_DraggingDirection > 0);
+ }
+
+ Rect CalculatePosition(float x, float y, float width, float height)
+ {
+ var rect = new Rect(x, y, width, height);
+ // TODO - Clamp to parent rect.
+ return rect;
+ }
+
+ ///
+ /// Called when the card is dropped.
+ ///
+ /// The old index
+ /// The new index
+ internal void OnDrop(int oldIndex, int newIndex)
+ {
+ dropped?.Invoke(oldIndex, newIndex);
+ }
+
+ void OnMouseDown(MouseDownEvent e)
+ {
+ if (cardView == null || panel?.GetCapturingElement(PointerId.mousePointerId) != null)
+ return;
+
+ if (!cardView.interactable || m_Active)
+ {
+ e.StopImmediatePropagation();
+ return;
+ }
+
+ if (panel?.GetCapturingElement(PointerId.mousePointerId) != null)
+ {
+ return;
+ }
+
+ if (e.button == (int)MouseButton.LeftMouse)
+ {
+ m_StartMousePos = e.localMousePosition;
+ m_Active = true;
+ this.CaptureMouse();
+ e.StopPropagation();
+ }
+ }
+
+ void OnMouseMove(MouseMoveEvent e)
+ {
+ if (m_Active)
+ {
+ // Ensure the card is selected when we start dragging it.
+ Select();
+
+ var diff = e.localMousePosition - m_StartMousePos;
+
+ if (!dragged && Math.Abs(diff.x) > 5)
+ {
+ dragged = true;
+ return;
+ }
+
+ if (!dragged)
+ {
+ return;
+ }
+
+ var targetScale = transform.scale;
+ diff.x *= targetScale.x;
+ diff.y *= targetScale.y;
+
+ var rect = CalculatePosition(layout.x + diff.x, layout.y + diff.y, layout.width, layout.height);
+ var oldLeft = style.left.value.value;
+
+ style.left = rect.x;
+ draggingDirection = oldLeft < style.left.value.value ? -1 : 1;
+ cardView.Drag(this);
+ e.StopPropagation();
+ }
+ }
+
+ void OnMouseUp(MouseUpEvent e)
+ {
+ if (m_Active)
+ {
+ if (e.button == (int)MouseButton.LeftMouse)
+ {
+ // Select or unselect the card if we didn't drag it.
+ if (!m_Dragged)
+ {
+ if (selected)
+ {
+ Deselect();
+ }
+ else
+ {
+ Select();
+ }
+ }
+
+ m_Active = false;
+ dragged = false;
+ this.ReleaseMouse();
+ e.StopPropagation();
+ }
+ }
+ }
+ }
+}
diff --git a/Assets/Scripts/UITk/Card.cs.meta b/Assets/Scripts/UITk/LetterCardViewItem.cs.meta
similarity index 100%
rename from Assets/Scripts/UITk/Card.cs.meta
rename to Assets/Scripts/UITk/LetterCardViewItem.cs.meta
diff --git a/Assets/Scripts/UITk/MainView.cs b/Assets/Scripts/UITk/MainView.cs
index a7c62a7..3ef6da4 100644
--- a/Assets/Scripts/UITk/MainView.cs
+++ b/Assets/Scripts/UITk/MainView.cs
@@ -14,200 +14,21 @@
namespace Unity.Samples.LetterSpell
{
- class PlayerSettingsData : INotifyBindablePropertyChanged
- {
- const string k_UsernamePref = "Username";
- const string k_DifficultyPref = "GameDifficulty";
- const string k_WordsPref = "GameWords";
- const string k_CluePref = "ShowClues";
- const string k_SoundEffectsPref = "SoundEffectsVolume";
- const string k_MusicPref = "MusicVolume";
- const string k_ColorThemePref = "ColorTheme";
- const string k_DisplaySizePref = "DisplaySize";
-
- [CreateProperty]
- public string username
- {
- get => PlayerPrefs.GetString(k_UsernamePref);
- set
- {
- if (username == value)
- {
- return;
- }
-
- PlayerPrefs.SetString(k_UsernamePref, value);
- Notify();
- }
- }
-
- [CreateProperty]
- public int difficultyLevel
- {
- get => PlayerPrefs.GetInt(k_DifficultyPref, 0);
- set
- {
- if (difficultyLevel == value)
- {
- return;
- }
-
- PlayerPrefs.SetInt(k_DifficultyPref, value);
- Notify();
- }
- }
-
- [CreateProperty]
- public bool isThreeWords
- {
- get => wordsCount == 0;
- set => wordsCount = value ? 0 : 1;
- }
-
- [CreateProperty]
- public bool isSixWords
- {
- get => wordsCount == 1;
- set => wordsCount = value ? 1 : 0;
- }
-
- [CreateProperty]
- public int wordsCount
- {
- get => PlayerPrefs.GetInt(k_WordsPref, 0);
- set
- {
- if (wordsCount == value)
- {
- return;
- }
-
- PlayerPrefs.SetInt(k_WordsPref, value);
- Notify(nameof(isSixWords));
- Notify(nameof(isThreeWords));
- }
- }
-
- [CreateProperty]
- public bool showSpellingClues
- {
- get => PlayerPrefs.GetInt(k_CluePref, 0) == 1;
- set
- {
- if (showSpellingClues == value)
- {
- return;
- }
-
- PlayerPrefs.SetInt(k_CluePref, value ? 1 : 0);
- Notify();
- }
- }
-
- [CreateProperty]
- public float soundEffectVolume
- {
- get => PlayerPrefs.GetFloat(k_SoundEffectsPref, 0.5f);
- set
- {
- if (Mathf.Approximately(soundEffectVolume, value))
- {
- return;
- }
-
- PlayerPrefs.SetFloat(k_SoundEffectsPref, value);
- Notify();
- }
- }
-
- [CreateProperty]
- public float musicVolume
- {
- get => PlayerPrefs.GetFloat(k_MusicPref, 0.5f);
- set
- {
- if (Mathf.Approximately(musicVolume, value))
- {
- return;
- }
-
- PlayerPrefs.SetFloat(k_MusicPref, value);
-
- if (AudioManager.instance != null)
- {
- AudioManager.instance.SetMusicVolume(value);
- }
- Notify();
- }
- }
-
- [CreateProperty]
- public int colorTheme
- {
- get => PlayerPrefs.GetInt(k_ColorThemePref, 0);
- set
- {
- if (colorTheme == value)
- {
- return;
- }
-
- PlayerPrefs.SetInt(k_ColorThemePref, value);
- Notify();
- }
- }
-
- [CreateProperty]
- public float displaySize
- {
- get => PlayerPrefs.GetFloat(k_DisplaySizePref, 0.5f);
- set
- {
- if (Mathf.Approximately(displaySize, value))
- {
- return;
- }
-
- PlayerPrefs.SetFloat(k_DisplaySizePref, value);
- Notify();
- }
- }
-
- [CreateProperty]
- public string closedCaptionsEnabledText => LocalizationSettings.StringDatabase.GetLocalizedString("Game Text", AccessibilitySettings.isClosedCaptioningEnabled ? "SETTING_ON" : "SETTING_OFF");
-
- [CreateProperty]
- public string boldTextEnabledText => LocalizationSettings.StringDatabase.GetLocalizedString("Game Text", AccessibilitySettings.isBoldTextEnabled ? "SETTING_ON" : "SETTING_OFF");
-
- [CreateProperty]
- public float fontScale => AccessibilitySettings.fontScale;
-
- public event EventHandler propertyChanged;
-
- public void Notify([CallerMemberName] string property = "")
- {
- propertyChanged?.Invoke(this, new BindablePropertyChangedEventArgs(property));
- }
- }
-
class MainView : MonoBehaviour
{
PlayerSettingsData m_PlayerSettings = new();
StackView m_StackView;
VisualElement m_MainView;
- // VisualElement m_Logo;
VisualElement m_SplashView;
VisualElement m_LoginView;
Button m_LoginButton;
Button m_EasyButton;
Button m_HardButton;
- Button m_StartGameButton;
- VisualElement m_LevelChoiceView;
-
+ VisualElement m_MainMenu;
VisualElement m_GameView;
Label m_ClueLabel;
VisualElement m_SuccessPill;
- CardListView m_LetterCardContainer;
+ LetterCardView m_LetterCardView;
Button m_PauseGameButton;
Button m_NextWordButton;
Button m_ExitGameButton;
@@ -232,11 +53,9 @@ class MainView : MonoBehaviour
VisualElement m_LastView;
LetterCardListModel m_Model = new();
-
- // Label m_AnswerLabel;
-
Gameplay.DifficultyLevel m_SelectedDifficultyLevel = Gameplay.DifficultyLevel.Hard;
-
+ LetterCardViewItem m_AccessibilityFocusedCard; // The card that has the accessibility focus.
+
Gameplay.DifficultyLevel selectedDifficultyLevel
{
get => m_SelectedDifficultyLevel;
@@ -253,12 +72,7 @@ void UpdateChoiceButtons()
m_EasyButton.EnableInClassList("selected", m_SelectedDifficultyLevel == Gameplay.DifficultyLevel.Easy);
}
- ///
- /// The focused card.
- ///
- UITkLetterCard m_AccessibilityFocusedCard;
-
- UITkLetterCard accessibilityFocusedCard
+ LetterCardViewItem accessibilityFocusedCard
{
get => m_AccessibilityFocusedCard;
set
@@ -275,7 +89,7 @@ UITkLetterCard accessibilityFocusedCard
// This can happen when the user is not dragging a card and just navigating the screen reader
// focus using swipe gestures.
// Note: we don't want to steal the focus if the user is dragging a card.
- if (m_AccessibilityFocusedCard != null && m_LetterCardContainer.selectedCard == null)
+ if (m_AccessibilityFocusedCard != null && m_LetterCardView.selectedCard == null)
{
m_AccessibilityFocusedCard.Focus();
}
@@ -340,23 +154,17 @@ void SetupUI()
m_LoginView = m_StackView.Q("loginView");
m_LoginView.dataSource = m_PlayerSettings;
-
- m_LoginButton = m_LoginView.Q