A Blockly MetricsManager that makes fixed edges more easily configurable.
yarn add @blockly/fixed-edges
npm install @blockly/fixed-edges --save
import * as Blockly from 'blockly';
import {FixedEdgesMetricsManager} from '@blockly/fixed-edges';
// Configure fixed edges
FixedEdgesMetricsManager.setFixedEdges({
top: true,
left: true,
});
// Inject Blockly.
const workspace = Blockly.inject('blocklyDiv', {
toolbox: toolboxCategories,
plugins: {
metricsManager: FixedEdgesMetricsManager,
},
});
setFixedEdges
: Configures which edges are fixed. This does not prevent fixed edges set by no scrollbars or single-direction scrollbars.
Apache 2.0