Trashcan Flyout doesn't close after dragging blocks from it to workspace

214 views
Skip to first unread message

Pola Hano

unread,
Jul 19, 2021, 6:37:38 AM7/19/21
to Blockly
when I open trashcan, its flyout appears and when I close the flyout by dragging a block or by (Esc) button on keyboard, it disappears but it still has effect on blocks.
when I drag blocks to trashcan flyout area it is deleted !!
The video attached demonstrates what I mean.
I use continuous-toolbox plugin.
I searched everywhere but I can't find a solution :/ . I will be so grateful if someone helped. 
and I have an unexplained behavior .. when I deactivate trashcan in injection code, it still exists:

var workspace = Blockly.inject(blocklyDiv, {
  plugins: {
    'toolbox': ContinuousToolbox,
    'flyoutsVerticalToolbox': ContinuousFlyout,
    'metricsManager': ContinuousMetrics,
  },
  toolbox: toolbox,
  media: './node_modules/blockly/media/',
  scrollbars: true,
 // trashcan: true,
  sounds: true,
  oneBasedIndex: true,
  zoom: {
    controls: true,
    wheel: false,
    startScale: 0.7,
    maxScale: 3,
    minScale: 0.3,
    scaleSpeed: 1.2
  },
  renderer: "zelos",
});
Rec 0002.mp4

Maribeth Bottorff

unread,
Jul 19, 2021, 6:43:48 PM7/19/21
to Blockly
Hi, can you please share
1. Which version of Blockly you are using
2. Which version of the continuous-toolbox you are using
3. Does this reproduce if you use the standard toolbox (comment out the plugins part of the inject options)?

This seems like a bug but I can't reproduce it here https://google.github.io/blockly-samples/plugins/continuous-toolbox/test/#grid.spacing=20&move.wheel=true but we may need to check an older version. Thanks!

Aaron Dodson

unread,
Jul 19, 2021, 6:44:39 PM7/19/21
to Blockly
Hi,

I wasn't able to recreate the behavior you're seeing with the delete area, but it appears it may be related to https://github.com/google/blockly/issues/4811 which was recently fixed in the Q2 2021 release. Which versions of Blockly and the continuous toolbox plugin are you using? If you haven't updated Blockly to the Q2 2021 release yet that might take care of it.

Regarding the trashcan still appearing even when removed from the call to inject, the trashcan is shown by default if your toolbox has categories (which it appears to from your screencast); does explicitly setting trashcan: false work to hide it?

- Aaron

On Monday, July 19, 2021 at 3:37:38 AM UTC-7 pola...@gmail.com wrote:

Pola Hano

unread,
Jul 20, 2021, 7:37:04 AM7/20/21
to Blockly
Hi Maribeth and Aaron,
thanks for your response.
here are versions I use:
"dependencies": {
        "@blockly/continuous-toolbox": "^1.0.12",
        "blockly": "^6.20210701.0"
    }
and this is how I call them in my html file:
  <script src="./node_modules/blockly/blockly_compressed.js"></script>
  <script src="./node_modules/blockly/blocks_compressed.js"></script>
  <script src="./node_modules/blockly/msg/js/en.js"></script>
  <script src="./node_modules/@blockly/continuous-toolbox/dist/index.js"></script>

- standard toolbox works well, Maribeth.
- false works for trashcan, Aaron.

should I check older verions of blockly or continuous-toolbox plugin ?

Thanks in advance.

Pola Hano

unread,
Jul 22, 2021, 4:29:09 AM7/22/21
to Blockly
is there any suggestions ?

Aaron Dodson

unread,
Jul 26, 2021, 11:07:00 AM7/26/21
to Blockly
Not that I can see immediately - it looks like you're on the latest/current versions, and I don't think downgrading would help. I'm going to look into this some more and check with the team if we want to open a tracking bug and circle back - the screencast you included was very helpful as well.

Pola Hano

unread,
Jul 26, 2021, 3:43:31 PM7/26/21
to Blockly

that's the repo of application if it helps: https://github.com/polahano/electron_app-html-design 
I hope to hear good news soon.

Aaron Dodson

unread,
Jul 26, 2021, 6:12:45 PM7/26/21
to blo...@googlegroups.com
Ah, that is helpful! I'm able to repro the issue with your repo, will investigate more in the next couple days.

--
You received this message because you are subscribed to the Google Groups "Blockly" group.
To unsubscribe from this group and stop receiving emails from it, send an email to blockly+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/blockly/dae2791a-2873-4ff1-868a-71e204914148n%40googlegroups.com.

Beka Westberg

unread,
Jul 28, 2021, 9:49:02 AM7/28/21
to blo...@googlegroups.com
Hello,

We have been able to reproduce this with your application :D Thank you so much for posting it! Sadly we haven't been able to track down the problem yet. The weird thing is that we can't reproduce this on our continuous toolbox demo, which also has a trash can. We'll continue to work on this and get back to you when we have more info =)

Thank you again!
--Beka 

On Mon, Jul 26, 2021 at 12:43 PM Pola Hano <pola...@gmail.com> wrote:
--

Pola Hano

unread,
Jul 28, 2021, 6:23:22 PM7/28/21
to Blockly
Thanks a lot for your effort :) .

Beka Westberg

unread,
Jul 28, 2021, 7:24:38 PM7/28/21
to blo...@googlegroups.com
Hello,

Aaron has found a fix for the problem! If you want to check out the change (it was surprisingly simple) you can view the pull request here. It doesn't seem like we're going to put out a patch release for this, so this will be included in the September 30, 2021 release of Blockly. But if that changes I'll be sure to let you know!

Best wishes,
Beka

Pola Hano

unread,
Jul 30, 2021, 11:14:44 AM7/30/21
to Blockly
Wow Great!
it is really so simple!
thanks a lot for  your care and efforts.

Reply all
Reply to author
Forward
0 new messages