UNPKG

devextreme

Version:

HTML5 JavaScript Component Suite for Responsive Web Development

36 lines (35 loc) 1.23 kB
/** * DevExtreme (esm/__internal/scheduler/r1/components/templates/public_template.js) * Version: 24.2.7 * Build date: Mon Apr 28 2025 * * Copyright (c) 2012 - 2025 Developer Express Inc. ALL RIGHTS RESERVED * Read about DevExtreme licensing here: https://js.devexpress.com/Licensing/ */ import _extends from "@babel/runtime/helpers/esm/extends"; import { createFragment } from "inferno"; import { equalByValue } from "../../../../../core/utils/common"; import { getTemplate } from "../../../../core/r1/utils/index"; export const PublicTemplate = _ref => { let { template: template, templateProps: templateProps, renderOptions: renderOptions } = _ref; if (void 0 === template) { return createFragment() } const templateFn = getTemplate(template); const templatePropsWithComparer = _extends({}, templateProps, { data: _extends({}, templateProps.data ?? {}, { isEqual: (null === renderOptions || void 0 === renderOptions ? void 0 : renderOptions.propsComparer) ?? equalByValue }) }); return null === templateFn || void 0 === templateFn ? void 0 : templateFn(templatePropsWithComparer) };