mirror of
https://github.com/google/blockly.git
synced 2026-01-10 10:27:08 +01:00
* fix: interface to match design * fix: dragger implementation * fix: rename moveToStart to revertDrag * fixup
25 lines
516 B
TypeScript
25 lines
516 B
TypeScript
/**
|
|
* @license
|
|
* Copyright 2019 Google LLC
|
|
* SPDX-License-Identifier: Apache-2.0
|
|
*/
|
|
|
|
// Former goog.module ID: Blockly.IDeletable
|
|
|
|
/**
|
|
* The interface for an object that can be deleted.
|
|
*/
|
|
export interface IDeletable {
|
|
/**
|
|
* Get whether this object is deletable or not.
|
|
*
|
|
* @returns True if deletable.
|
|
*/
|
|
isDeletable(): boolean;
|
|
}
|
|
|
|
/** Returns whether the given object is an IDeletable. */
|
|
export function isDeletable(obj: any): obj is IDeletable {
|
|
return obj['isDeletable'] !== undefined;
|
|
}
|