From a3e414ef54aa93494b760b4dfa2e1383d6ff4bdf Mon Sep 17 00:00:00 2001
From: Paul Kaplan <pkaplan@media.mit.edu>
Date: Wed, 20 Dec 2017 17:28:15 -0500
Subject: [PATCH] Change "More" category to "My Blocks.

---
 src/components/blocks/blocks.css | 9 +++++++++
 src/lib/make-toolbox-xml.js      | 6 +++---
 test/integration/test.js         | 2 +-
 3 files changed, 13 insertions(+), 4 deletions(-)

diff --git a/src/components/blocks/blocks.css b/src/components/blocks/blocks.css
index 6c5858efd..ee9ec8aeb 100644
--- a/src/components/blocks/blocks.css
+++ b/src/components/blocks/blocks.css
@@ -28,3 +28,12 @@ $border-style: 1px solid $ui-pane-border;
     border-right: $border-style;
     box-sizing: content-box;
 }
+
+/*
+    Shrink category font to fit "My Blocks" for now.
+    Probably will need different solutions for language support later, so
+    make the change here instead of in scratch-blocks.
+*/
+.blocks :global(.scratchCategoryMenuItemLabel) {
+    font-size: 0.65rem;
+}
diff --git a/src/lib/make-toolbox-xml.js b/src/lib/make-toolbox-xml.js
index 637188ef7..b83bb9376 100644
--- a/src/lib/make-toolbox-xml.js
+++ b/src/lib/make-toolbox-xml.js
@@ -648,9 +648,9 @@ const data = function () {
     `;
 };
 
-const more = function () {
+const myBlocks = function () {
     return `
-    <category name="More" colour="#FF6680" secondaryColour="#FF4D6A" custom="PROCEDURE">
+    <category name="My Blocks" colour="#FF6680" secondaryColour="#FF4D6A" custom="PROCEDURE">
     </category>
     `;
 };
@@ -677,7 +677,7 @@ const makeToolboxXML = function (isStage, targetId, categoriesXML) {
         sensing(isStage, targetId), gap,
         operators(isStage, targetId), gap,
         data(isStage, targetId), gap,
-        more(isStage, targetId)
+        myBlocks(isStage, targetId)
     ];
 
     if (categoriesXML) {
diff --git a/test/integration/test.js b/test/integration/test.js
index 8668fce2a..4d6866bba 100644
--- a/test/integration/test.js
+++ b/test/integration/test.js
@@ -219,7 +219,7 @@ describe('costumes, sounds and variables', () => {
 
     test('Custom procedures', async () => {
         await loadUri(uri);
-        await clickText('More');
+        await clickText('My Blocks');
         await new Promise(resolve => setTimeout(resolve, 1000)); // Wait for scroll animation
         await clickText('Make a Block...');
         // Click on the "add an input" buttons
-- 
GitLab