pixi.js
Version:
PixiJS — The HTML5 Creation Engine =============
14 lines (11 loc) • 424 B
JavaScript
import { HTMLTextStyle } from '../../text-html/HtmlTextStyle.mjs';
import { TextStyle } from '../TextStyle.mjs';
;
function ensureTextStyle(renderMode, style) {
if (style instanceof TextStyle || style instanceof HTMLTextStyle) {
return style;
}
return renderMode === "html" ? new HTMLTextStyle(style) : new TextStyle(style);
}
export { ensureTextStyle };
//# sourceMappingURL=ensureTextStyle.mjs.map