Skip to content

Commit 539ae4f

Browse files
committed
revert: "fix(FieldMultilineInput): Use string literal instead of Field.NBSP"
This reverts commit 96b299b.
1 parent 9dc3124 commit 539ae4f

1 file changed

Lines changed: 2 additions & 5 deletions

File tree

plugins/field-multilineinput/src/field_multilineinput.ts

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -163,11 +163,9 @@ export class FieldMultilineInput extends Blockly.FieldTextInput {
163163
);
164164
}
165165
let textLines = this.getText();
166-
// TODO(google/blockly#8738): Use minimum-width setting mechanism
167-
// to be introduced in PR #9011.
168166
if (!textLines) {
169167
// Prevent the field from disappearing if empty.
170-
return '\u00A0'; // Non-breaking space.
168+
return Blockly.Field.NBSP;
171169
}
172170
const lines = textLines.split('\n');
173171
textLines = '';
@@ -184,8 +182,7 @@ export class FieldMultilineInput extends Blockly.FieldTextInput {
184182
}
185183
// Replace whitespace with non-breaking spaces so the text doesn't
186184
// collapse.
187-
// TODO(google/blockly#8738): Use Blockly.Field.NBSP.
188-
text = text.replace(/\s/g, '\u00A0'); // Non-breaking space.
185+
text = text.replace(/\s/g, Blockly.Field.NBSP);
189186

190187
textLines += text;
191188
if (i !== displayLinesNumber - 1) {

0 commit comments

Comments
 (0)