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

feat: add legacy warning to block factory #8234

Merged
merged 1 commit into from
Jun 28, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion demos/blockfactory/app_controller.js
Original file line number Diff line number Diff line change
Expand Up @@ -507,7 +507,7 @@ AppController.prototype.assignBlockFactoryClickHandlers = function() {

document.getElementById('helpButton').addEventListener('click',
function() {
open('https://developers.google.com/blockly/custom-blocks/block-factory',
open('https://developers.google.com/blockly/guides/create-custom-blocks/legacy-blockly-developer-tools',
'BlockFactoryHelp');
});

Expand Down
7 changes: 7 additions & 0 deletions demos/blockfactory/factory.css
Original file line number Diff line number Diff line change
Expand Up @@ -127,6 +127,13 @@ button, .buttonStyle {
float: right;
}

#legacyBanner {
border: #ccc 1px solid;
background-color: #FFCDD2;
margin: 4px;
padding: 4px;
}

#blockFactoryContent {
height: 85%;
width: 100%;
Expand Down
3 changes: 3 additions & 0 deletions demos/blockfactory/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,9 @@ <h1><a href="https://developers.google.com/blockly/">Blockly</a> &gt;
<button class="privacyButton" title="Open Google privacy policy"><a class="privacyLink" href="https://policies.google.com/privacy">Privacy</a>
</button>
</h1>
<div id="legacyBanner">
This version of Developer Tools is only compatible with Blockly version 10 and earlier. Try the <a target="_blank" href="https://google.github.io/blockly-samples/examples/developer-tools/index.html">new Block Factory</a> and <a target="_blank" href="https://developers.google.com/blockly/guides/create-custom-blocks/blockly-developer-tools#import_from_legacy_block_factory">learn how to migrate your blocks</a>.
</div>
<div id="tabContainer">
<div id="blockFactory_tab" class="tab tabon">Block Factory</div>
<div id="blocklibraryExporter_tab" class="tab taboff">Block Exporter</div>
Expand Down
Loading