Skip to content

Commit

Permalink
Fix template for svg elements (#368)
Browse files Browse the repository at this point in the history
* Fix template for svg elements

* Fix lint
  • Loading branch information
dxvladislavvolkov authored May 20, 2020
1 parent a81e646 commit 0dc4ec1
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/core/templates-manager.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ import {
mountTemplate
} from "./templates-discovering";

import * as domAdapter from "devextreme/core/dom_adapter";
import * as events from "devextreme/events";
import { DX_REMOVE_EVENT, DX_TEMPLATE_WRAPPER_CLASS } from "./constants";
import { allKeysAreEqual } from "./helpers";
Expand Down Expand Up @@ -74,9 +75,8 @@ class TemplatesManager {
);

const element = mountedTemplate.$el;
if (element.classList) {
element.classList.add(DX_TEMPLATE_WRAPPER_CLASS);
}

domAdapter.setClass(element, DX_TEMPLATE_WRAPPER_CLASS, true);

if (element.nodeType === Node.TEXT_NODE) {
const removalListener = document.createElement(container.nodeName === "TABLE" ? "tbody" : "span");
Expand Down

0 comments on commit 0dc4ec1

Please sign in to comment.