UNPKG

mui-spfx-controls

Version:
67 lines 2.63 kB
import { __awaiter, __extends, __generator } from "tslib"; import { Version } from '@microsoft/sp-core-library'; import { PropertyPaneTextField, } from '@microsoft/sp-property-pane'; import { BaseClientSideWebPart } from '@microsoft/sp-webpart-base'; import * as React from 'react'; import * as ReactDom from 'react-dom'; import * as strings from 'SiteBreadcrumbWebPartStrings'; import SiteBreadcrumbDisplay from './SiteBreadcrumbDisplay'; var SiteBreadcrumbWebPart = /** @class */ (function (_super) { __extends(SiteBreadcrumbWebPart, _super); function SiteBreadcrumbWebPart() { return _super !== null && _super.apply(this, arguments) || this; } SiteBreadcrumbWebPart.prototype.render = function () { var element = React.createElement(SiteBreadcrumbDisplay, { context: this.context, separator: this.properties.separator, }); ReactDom.render(element, this.domElement); }; SiteBreadcrumbWebPart.prototype.onInit = function () { return __awaiter(this, void 0, void 0, function () { return __generator(this, function (_a) { switch (_a.label) { case 0: return [4 /*yield*/, _super.prototype.onInit.call(this)]; case 1: _a.sent(); return [2 /*return*/]; } }); }); }; SiteBreadcrumbWebPart.prototype.onDispose = function () { ReactDom.unmountComponentAtNode(this.domElement); }; Object.defineProperty(SiteBreadcrumbWebPart.prototype, "dataVersion", { get: function () { return Version.parse('1.0'); }, enumerable: false, configurable: true }); SiteBreadcrumbWebPart.prototype.getPropertyPaneConfiguration = function () { return { pages: [ { header: { description: strings.PropertyPaneDescription, }, groups: [ { groupName: strings.BasicGroupName, groupFields: [ PropertyPaneTextField('separator', { label: strings.SeparatorFieldLabel, }), ], }, ], }, ], }; }; return SiteBreadcrumbWebPart; }(BaseClientSideWebPart)); export default SiteBreadcrumbWebPart; //# sourceMappingURL=SiteBreadcrumbWebPart.js.map