mirror of
https://github.com/google/blockly.git
synced 2026-01-08 17:40:09 +01:00
fix: Use require instead of requireType for interfaces (#5568)
But only if the interface is used in an @implements or @extends declaration. Fixes #5450
This commit is contained in:
committed by
GitHub
parent
c5ffd036ca
commit
d2d5dc4b71
@@ -18,7 +18,7 @@
|
||||
goog.module('Blockly.IASTNodeLocationSvg');
|
||||
|
||||
/* eslint-disable-next-line no-unused-vars */
|
||||
const IASTNodeLocation = goog.requireType('Blockly.IASTNodeLocation');
|
||||
const IASTNodeLocation = goog.require('Blockly.IASTNodeLocation');
|
||||
|
||||
|
||||
/**
|
||||
|
||||
@@ -20,7 +20,7 @@
|
||||
goog.module('Blockly.IASTNodeLocationWithBlock');
|
||||
|
||||
/* eslint-disable-next-line no-unused-vars */
|
||||
const IASTNodeLocation = goog.requireType('Blockly.IASTNodeLocation');
|
||||
const IASTNodeLocation = goog.require('Blockly.IASTNodeLocation');
|
||||
/* eslint-disable-next-line no-unused-vars */
|
||||
const {Block} = goog.requireType('Blockly.Block');
|
||||
|
||||
|
||||
@@ -20,7 +20,7 @@
|
||||
goog.module('Blockly.IAutoHideable');
|
||||
|
||||
/* eslint-disable-next-line no-unused-vars */
|
||||
const IComponent = goog.requireType('Blockly.IComponent');
|
||||
const IComponent = goog.require('Blockly.IComponent');
|
||||
|
||||
|
||||
/**
|
||||
|
||||
@@ -20,9 +20,9 @@ goog.module('Blockly.IBubble');
|
||||
/* eslint-disable-next-line no-unused-vars */
|
||||
const Coordinate = goog.requireType('Blockly.utils.Coordinate');
|
||||
/* eslint-disable-next-line no-unused-vars */
|
||||
const IContextMenu = goog.requireType('Blockly.IContextMenu');
|
||||
const IContextMenu = goog.require('Blockly.IContextMenu');
|
||||
/* eslint-disable-next-line no-unused-vars */
|
||||
const IDraggable = goog.requireType('Blockly.IDraggable');
|
||||
const IDraggable = goog.require('Blockly.IDraggable');
|
||||
/* eslint-disable-next-line no-unused-vars */
|
||||
const {BlockDragSurfaceSvg} = goog.requireType('Blockly.BlockDragSurfaceSvg');
|
||||
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
goog.module('Blockly.ICollapsibleToolboxItem');
|
||||
|
||||
/* eslint-disable-next-line no-unused-vars */
|
||||
const ISelectableToolboxItem = goog.requireType('Blockly.ISelectableToolboxItem');
|
||||
const ISelectableToolboxItem = goog.require('Blockly.ISelectableToolboxItem');
|
||||
/* eslint-disable-next-line no-unused-vars */
|
||||
const IToolboxItem = goog.requireType('Blockly.IToolboxItem');
|
||||
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
goog.module('Blockly.ICopyable');
|
||||
|
||||
/* eslint-disable-next-line no-unused-vars */
|
||||
const ISelectable = goog.requireType('Blockly.ISelectable');
|
||||
const ISelectable = goog.require('Blockly.ISelectable');
|
||||
/* eslint-disable-next-line no-unused-vars */
|
||||
const WorkspaceSvg = goog.requireType('Blockly.WorkspaceSvg');
|
||||
|
||||
|
||||
@@ -22,7 +22,7 @@ goog.module('Blockly.IDeleteArea');
|
||||
/* eslint-disable-next-line no-unused-vars */
|
||||
const IDraggable = goog.requireType('Blockly.IDraggable');
|
||||
/* eslint-disable-next-line no-unused-vars */
|
||||
const IDragTarget = goog.requireType('Blockly.IDragTarget');
|
||||
const IDragTarget = goog.require('Blockly.IDragTarget');
|
||||
|
||||
|
||||
/**
|
||||
|
||||
@@ -20,7 +20,7 @@
|
||||
goog.module('Blockly.IDragTarget');
|
||||
|
||||
/* eslint-disable-next-line no-unused-vars */
|
||||
const IComponent = goog.requireType('Blockly.IComponent');
|
||||
const IComponent = goog.require('Blockly.IComponent');
|
||||
/* eslint-disable-next-line no-unused-vars */
|
||||
const IDraggable = goog.requireType('Blockly.IDraggable');
|
||||
/* eslint-disable-next-line no-unused-vars */
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
goog.module('Blockly.IDraggable');
|
||||
|
||||
/* eslint-disable-next-line no-unused-vars */
|
||||
const IDeletable = goog.requireType('Blockly.IDeletable');
|
||||
const IDeletable = goog.require('Blockly.IDeletable');
|
||||
|
||||
|
||||
/**
|
||||
|
||||
@@ -20,7 +20,7 @@ goog.module('Blockly.IFlyout');
|
||||
/* eslint-disable-next-line no-unused-vars */
|
||||
const Coordinate = goog.requireType('Blockly.utils.Coordinate');
|
||||
/* eslint-disable-next-line no-unused-vars */
|
||||
const IRegistrable = goog.requireType('Blockly.IRegistrable');
|
||||
const IRegistrable = goog.require('Blockly.IRegistrable');
|
||||
/* eslint-disable-next-line no-unused-vars */
|
||||
const Svg = goog.requireType('Blockly.utils.Svg');
|
||||
/* eslint-disable-next-line no-unused-vars */
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
goog.module('Blockly.IPositionable');
|
||||
|
||||
/* eslint-disable-next-line no-unused-vars */
|
||||
const IComponent = goog.requireType('Blockly.IComponent');
|
||||
const IComponent = goog.require('Blockly.IComponent');
|
||||
/* eslint-disable-next-line no-unused-vars */
|
||||
const MetricsManager = goog.requireType('Blockly.MetricsManager');
|
||||
/* eslint-disable-next-line no-unused-vars */
|
||||
|
||||
@@ -18,9 +18,9 @@
|
||||
goog.module('Blockly.ISelectable');
|
||||
|
||||
// eslint-disable-next-line no-unused-vars
|
||||
const IDeletable = goog.requireType('Blockly.IDeletable');
|
||||
const IDeletable = goog.require('Blockly.IDeletable');
|
||||
// eslint-disable-next-line no-unused-vars
|
||||
const IMovable = goog.requireType('Blockly.IMovable');
|
||||
const IMovable = goog.require('Blockly.IMovable');
|
||||
|
||||
|
||||
/**
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
goog.module('Blockly.ISelectableToolboxItem');
|
||||
|
||||
/* eslint-disable-next-line no-unused-vars */
|
||||
const IToolboxItem = goog.requireType('Blockly.IToolboxItem');
|
||||
const IToolboxItem = goog.require('Blockly.IToolboxItem');
|
||||
/* eslint-disable-next-line no-unused-vars */
|
||||
const toolbox = goog.requireType('Blockly.utils.toolbox');
|
||||
|
||||
|
||||
@@ -20,7 +20,7 @@ goog.module('Blockly.IToolbox');
|
||||
/* eslint-disable-next-line no-unused-vars */
|
||||
const IFlyout = goog.requireType('Blockly.IFlyout');
|
||||
/* eslint-disable-next-line no-unused-vars */
|
||||
const IRegistrable = goog.requireType('Blockly.IRegistrable');
|
||||
const IRegistrable = goog.require('Blockly.IRegistrable');
|
||||
/* eslint-disable-next-line no-unused-vars */
|
||||
const IToolboxItem = goog.requireType('Blockly.IToolboxItem');
|
||||
/* eslint-disable-next-line no-unused-vars */
|
||||
|
||||
Reference in New Issue
Block a user