Changes Css.register API to accept string param (#5472)

* Chnages Css.register API to accept string param

* Address self review comments and nits

* Fix code-comment

* Address minor review comments and nits

* Allow passing an array of strings when registering CSS

* Fix lint errors

Co-authored-by: Aaron Dodson <adodson@google.com>
This commit is contained in:
Sandeep Dubey
2021-10-15 04:17:10 +05:30
committed by GitHub
parent abee92c7c9
commit ec9092fd67
14 changed files with 668 additions and 646 deletions

View File

@@ -433,19 +433,19 @@ FieldMultilineInput.prototype.onHtmlInputKeyDown_ = function(e) {
/**
* CSS for multiline field. See css.js for use.
*/
Css.register([
`.blocklyHtmlTextAreaInput {
font-family: monospace;
resize: none;
overflow: hidden;
height: 100%;
text-align: left;
}`,
`.blocklyHtmlTextAreaInputOverflowedY {
overflow-y: scroll;
}`
]);
Css.register(`
.blocklyHtmlTextAreaInput {
font-family: monospace;
resize: none;
overflow: hidden;
height: 100%;
text-align: left;
}
.blocklyHtmlTextAreaInputOverflowedY {
overflow-y: scroll;
}
`);
fieldRegistry.register('field_multilinetext', FieldMultilineInput);