Skip to content

Commit

Permalink
chore: format
Browse files Browse the repository at this point in the history
  • Loading branch information
rachel-fenichel committed Mar 8, 2022
1 parent a35efbf commit dc133ee
Show file tree
Hide file tree
Showing 6 changed files with 22 additions and 11 deletions.
3 changes: 2 additions & 1 deletion core/inject.js
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,8 @@ const inject = function(container, opt_options) {
}
const options =
new Options(opt_options || (/** @type {!BlocklyOptions} */ ({})));
const subContainer = /** @type {!HTMLDivElement} */ (document.createElement('div'));
const subContainer =
/** @type {!HTMLDivElement} */ (document.createElement('div'));
subContainer.className = 'injectionDiv';
subContainer.tabIndex = 0;
aria.setState(subContainer, aria.State.LABEL, Msg['WORKSPACE_ARIA_LABEL']);
Expand Down
9 changes: 6 additions & 3 deletions core/menuitem.js
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,8 @@ const MenuItem = class {
* @return {!Element} Completed DOM.
*/
createDom() {
const element = /** @type {!HTMLDivElement} */ (document.createElement('div'));
const element =
/** @type {!HTMLDivElement} */ (document.createElement('div'));
element.id = idGenerator.getNextUniqueId();
this.element_ = element;

Expand All @@ -121,11 +122,13 @@ const MenuItem = class {
'') +
(this.rightToLeft_ ? 'blocklyMenuItemRtl goog-menuitem-rtl ' : '');

const content = /** @type {!HTMLDivElement} */ (document.createElement('div'));
const content =
/** @type {!HTMLDivElement} */ (document.createElement('div'));
content.className = 'blocklyMenuItemContent goog-menuitem-content';
// Add a checkbox for checkable menu items.
if (this.checkable_) {
const checkbox = /** @type {!HTMLDivElement} */ (document.createElement('div'));
const checkbox =
/** @type {!HTMLDivElement} */ (document.createElement('div'));
checkbox.className = 'blocklyMenuItemCheckbox goog-menuitem-checkbox';
content.appendChild(checkbox);
}
Expand Down
9 changes: 6 additions & 3 deletions core/toolbox/category.js
Original file line number Diff line number Diff line change
Expand Up @@ -246,7 +246,8 @@ class ToolboxCategory extends ToolboxItem {
* @protected
*/
createContainer_() {
const container = /** @type {!HTMLDivElement} */ (document.createElement('div'));
const container =
/** @type {!HTMLDivElement} */ (document.createElement('div'));
dom.addClass(container, this.cssConfig_['container']);
return container;
}
Expand All @@ -258,7 +259,8 @@ class ToolboxCategory extends ToolboxItem {
* @protected
*/
createRowContainer_() {
const rowDiv = /** @type {!HTMLDivElement} */ (document.createElement('div'));
const rowDiv =
/** @type {!HTMLDivElement} */ (document.createElement('div'));
dom.addClass(rowDiv, this.cssConfig_['row']);
let nestedPadding = ToolboxCategory.nestedPadding * this.getLevel();
nestedPadding = nestedPadding.toString() + 'px';
Expand All @@ -274,7 +276,8 @@ class ToolboxCategory extends ToolboxItem {
* @protected
*/
createRowContentsContainer_() {
const contentsContainer = /** @type {!HTMLDivElement} */ (document.createElement('div'));
const contentsContainer =
/** @type {!HTMLDivElement} */ (document.createElement('div'));
dom.addClass(contentsContainer, this.cssConfig_['rowcontentcontainer']);
return contentsContainer;
}
Expand Down
3 changes: 2 additions & 1 deletion core/toolbox/collapsible_category.js
Original file line number Diff line number Diff line change
Expand Up @@ -174,7 +174,8 @@ class CollapsibleToolboxCategory extends ToolboxCategory {
* @protected
*/
createSubCategoriesDom_(subcategories) {
const contentsContainer = /** @type {!HTMLDivElement} */ (document.createElement('div'));
const contentsContainer =
/** @type {!HTMLDivElement} */ (document.createElement('div'));
dom.addClass(contentsContainer, this.cssConfig_['contents']);

for (let i = 0; i < subcategories.length; i++) {
Expand Down
3 changes: 2 additions & 1 deletion core/toolbox/separator.js
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,8 @@ class ToolboxSeparator extends ToolboxItem {
* @protected
*/
createDom_() {
const container = /** @type {!HTMLDivElement} */ (document.createElement('div'));
const container =
/** @type {!HTMLDivElement} */ (document.createElement('div'));
dom.addClass(container, this.cssConfig_['container']);
this.htmlDiv_ = container;
return container;
Expand Down
6 changes: 4 additions & 2 deletions core/toolbox/toolbox.js
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,8 @@ class Toolbox extends DeleteArea {
* @protected
*/
createContainer_() {
const toolboxContainer = /** @type {!HTMLDivElement} */ (document.createElement('div'));
const toolboxContainer =
/** @type {!HTMLDivElement} */ (document.createElement('div'));
toolboxContainer.setAttribute('layout', this.isHorizontal() ? 'h' : 'v');
dom.addClass(toolboxContainer, 'blocklyToolboxDiv');
dom.addClass(toolboxContainer, 'blocklyNonSelectable');
Expand All @@ -280,7 +281,8 @@ class Toolbox extends DeleteArea {
* @protected
*/
createContentsContainer_() {
const contentsContainer = /** @type {!HTMLDivElement} */ (document.createElement('div'));
const contentsContainer =
/** @type {!HTMLDivElement} */ (document.createElement('div'));
dom.addClass(contentsContainer, 'blocklyToolboxContents');
if (this.isHorizontal()) {
contentsContainer.style.flexDirection = 'row';
Expand Down

0 comments on commit dc133ee

Please sign in to comment.