Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can mutate blocks in readOnly workspace #7557

Closed
1 task done
michaela-mm opened this issue Sep 29, 2023 · 2 comments · Fixed by #7622
Closed
1 task done

Can mutate blocks in readOnly workspace #7557

michaela-mm opened this issue Sep 29, 2023 · 2 comments · Fixed by #7622
Assignees
Labels
good first issue issue: bug Describes why the code or behaviour is wrong size: small Bugs that can be picked up and completed in 1-3 days

Comments

@michaela-mm
Copy link

michaela-mm commented Sep 29, 2023

Check for duplicates

  • I have searched for similar issues before opening a new one.

Description

If there is a block with mutator in a readOnly workspace, I can click on the mutator icon, open the mutator bubble and change the block that way. I think the icon used to just be disabled pre-v10?

Reproduction steps

  1. Run npm run start and switch to the Advanced playground link.
  2. Drag in an if block
  3. Check the readOnly option and reload.
  4. You can add else and ifelse rows to the if block.

Stack trace

No response

Screenshots

image

Browsers

Chrome desktop

To Fix

  1. Run the reproduction steps to make sure you can replicate the issue.
  2. Modify the onClick method of the MutatorIcon to return early if this.sourceBlock.isEditable() is false.
  3. Rerun the reproduction steps and make sure you can't reproduce.
@michaela-mm michaela-mm added issue: bug Describes why the code or behaviour is wrong issue: triage Issues awaiting triage by a Blockly team member labels Sep 29, 2023
@maribethb maribethb added the size: small Bugs that can be picked up and completed in 1-3 days label Oct 11, 2023
@rachel-fenichel rachel-fenichel removed the issue: triage Issues awaiting triage by a Blockly team member label Oct 18, 2023
@BeksOmega BeksOmega added help wanted External contributions actively solicited good first issue and removed help wanted External contributions actively solicited labels Oct 23, 2023
@Apoorvgarg-creator
Copy link
Contributor

@BeksOmega @maribethb Can I take this issue ?

@BeksOmega
Copy link
Collaborator

Go for it @Apoorvgarg-creator =)

Apoorvgarg-creator added a commit to Apoorvgarg-creator/blockly that referenced this issue Oct 31, 2023
BeksOmega pushed a commit that referenced this issue Oct 31, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue issue: bug Describes why the code or behaviour is wrong size: small Bugs that can be picked up and completed in 1-3 days
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants