Skip to content

Commit

Permalink
fix: use blockly/core imports
Browse files Browse the repository at this point in the history
  • Loading branch information
maribethb committed Jan 4, 2024
1 parent 189f831 commit 18bcecc
Show file tree
Hide file tree
Showing 19 changed files with 24 additions and 19 deletions.
2 changes: 1 addition & 1 deletion examples/developer-tools/src/blocks/colour.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* SPDX-License-Identifier: Apache-2.0
*/

import * as Blockly from 'blockly';
import * as Blockly from 'blockly/core';

/**
* A hue-picker to set the colour of a block.
Expand Down
2 changes: 1 addition & 1 deletion examples/developer-tools/src/blocks/factory_base.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* SPDX-License-Identifier: Apache-2.0
*/

import * as Blockly from 'blockly';
import * as Blockly from 'blockly/core';

export const factoryBase = {
// Base of new block.
Expand Down
2 changes: 1 addition & 1 deletion examples/developer-tools/src/blocks/fields.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* SPDX-License-Identifier: Apache-2.0
*/

import * as Blockly from 'blockly';
import * as Blockly from 'blockly/core';

/**
* Check to see if more than one field has this name.
Expand Down
2 changes: 1 addition & 1 deletion examples/developer-tools/src/blocks/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
*/

import {factoryBase} from './factory_base';
import * as Blockly from 'blockly';
import * as Blockly from 'blockly/core';
import {input} from './input';
import {type, typeGroup, typeGroupContainer, typeGroupItem} from './type';
import {
Expand Down
2 changes: 1 addition & 1 deletion examples/developer-tools/src/blocks/input.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* SPDX-License-Identifier: Apache-2.0
*/

import * as Blockly from 'blockly';
import * as Blockly from 'blockly/core';

/**
* Check to see if more than one input has this name.
Expand Down
2 changes: 1 addition & 1 deletion examples/developer-tools/src/blocks/type.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* SPDX-License-Identifier: Apache-2.0
*/

import * as Blockly from 'blockly';
import * as Blockly from 'blockly/core';

interface TypeState {
typeCount: number;
Expand Down
7 changes: 6 additions & 1 deletion examples/developer-tools/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,9 @@
* SPDX-License-Identifier: Apache-2.0
*/

import * as Blockly from 'blockly';
import * as Blockly from 'blockly/core';
import * as En from 'blockly/msg/en';
import 'blockly/blocks';
import {registerAllBlocks} from './blocks';
import {toolbox} from './toolbox';
import './index.css';
Expand All @@ -14,6 +16,9 @@ import {load, save} from './serialization';
// Put Blockly in the global scope for easy debugging.
(window as any).Blockly = Blockly;

// Even though En should be loaded by default,
// if you don't load it specifically, you'll get spurious message warnings.
Blockly.setLocale(En);
registerAllBlocks();

const mainWorkspaceDiv = document.getElementById('mainWorkspace');
Expand Down
2 changes: 1 addition & 1 deletion examples/developer-tools/src/output-generators/colour.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import {
Order,
jsonDefinitionGenerator,
} from './json_definition_generator';
import * as Blockly from 'blockly';
import * as Blockly from 'blockly/core';

/**
* JSON definition for the "input" block.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* SPDX-License-Identifier: Apache-2.0
*/

import * as Blockly from 'blockly';
import * as Blockly from 'blockly/core';
import {javascriptGenerator} from 'blockly/javascript';
import {
JsonDefinitionGenerator,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* SPDX-License-Identifier: Apache-2.0
*/

import * as Blockly from 'blockly';
import * as Blockly from 'blockly/core';
import {
JsonDefinitionGenerator,
jsonDefinitionGenerator,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* SPDX-License-Identifier: Apache-2.0
*/

import * as Blockly from 'blockly';
import * as Blockly from 'blockly/core';
import {
JsonDefinitionGenerator,
jsonDefinitionGenerator,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* SPDX-License-Identifier: Apache-2.0
*/

import * as Blockly from 'blockly';
import * as Blockly from 'blockly/core';
import {
JsonDefinitionGenerator,
jsonDefinitionGenerator,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* SPDX-License-Identifier: Apache-2.0
*/

import * as Blockly from 'blockly';
import * as Blockly from 'blockly/core';
import {
JsonDefinitionGenerator,
jsonDefinitionGenerator,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* SPDX-License-Identifier: Apache-2.0
*/

import * as Blockly from 'blockly';
import * as Blockly from 'blockly/core';
import {
JsonDefinitionGenerator,
jsonDefinitionGenerator,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* SPDX-License-Identifier: Apache-2.0
*/

import * as Blockly from 'blockly';
import * as Blockly from 'blockly/core';
import {
JsonDefinitionGenerator,
jsonDefinitionGenerator,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* SPDX-License-Identifier: Apache-2.0
*/

import * as Blockly from 'blockly';
import * as Blockly from 'blockly/core';
import {
JsonDefinitionGenerator,
jsonDefinitionGenerator,
Expand Down
2 changes: 1 addition & 1 deletion examples/developer-tools/src/output-generators/input.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import {
Order,
jsonDefinitionGenerator,
} from './json_definition_generator';
import * as Blockly from 'blockly';
import * as Blockly from 'blockly/core';

/**
* JSON definition for the "input" block.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* SPDX-License-Identifier: Apache-2.0
*/

import * as Blockly from 'blockly';
import * as Blockly from 'blockly/core';

/**
* We will never need parentheses for the JSON definition, so
Expand Down
2 changes: 1 addition & 1 deletion examples/developer-tools/src/output-generators/type.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* SPDX-License-Identifier: Apache-2.0
*/

import * as Blockly from 'blockly';
import * as Blockly from 'blockly/core';
import {
JsonDefinitionGenerator,
Order,
Expand Down

0 comments on commit 18bcecc

Please sign in to comment.