office-ui-fabric-react
Version:
Reusable React components for building experiences for Office 365.
35 lines • 3.51 kB
JavaScript
import * as tslib_1 from "tslib";
import * as React from 'react';
import { Link } from 'office-ui-fabric-react/lib/Link';
import { ExampleCard, ComponentPage, PropertiesTableSet } from '@uifabric/example-app-base';
import { PeoplePickerTypesExample } from './examples/PeoplePicker.Types.Example';
import { ComponentStatus } from '../../../demo/ComponentStatus/ComponentStatus';
import { PeoplePickerStatus } from './PeoplePicker.checklist';
var PeoplePickerTypesExampleCode = require('!raw-loader!office-ui-fabric-react/src/components/pickers/PeoplePicker/examples/PeoplePicker.Types.Example.tsx');
var PeoplePickerPage = /** @class */ (function (_super) {
tslib_1.__extends(PeoplePickerPage, _super);
function PeoplePickerPage() {
return _super !== null && _super.apply(this, arguments) || this;
}
PeoplePickerPage.prototype.render = function () {
return (React.createElement(ComponentPage, { title: 'PeoplePicker', componentName: 'PeoplePickerExample', exampleCards: React.createElement("div", null,
React.createElement(ExampleCard, { title: 'People Pickers', code: PeoplePickerTypesExampleCode },
React.createElement(PeoplePickerTypesExample, null))), propertiesTables: React.createElement(PropertiesTableSet, { sources: [
require('!raw-loader!office-ui-fabric-react/src/components/pickers/BasePicker.types.ts')
] }), overview: React.createElement("div", null,
React.createElement(Link, { target: '_blank', href: 'http://dev.office.com/fabric/components/PeoplePicker' }, " PeoplePicker "),
React.createElement("span", null, " are used to pick recipients.")), isHeaderVisible: this.props.isHeaderVisible, bestPractices: React.createElement("div", null, "The PeoplePicker is used to select one or more entities, such as people or groups. Entry points for PeoplePickers are typically specialized TextField-like input fields known as a \"well\", which are used to search for recipients from a list. When a recipient is selected from the list, it is added to the well as a specialized Persona that can be interacted with or removed. Clicking on a Persona from the well should invoke a PersonaCard or open a profile pane for that recipient."), dos: React.createElement("div", null,
React.createElement("ul", null,
React.createElement("li", null, "Use the PeoplePicker to quickly search for a few people"),
React.createElement("li", null, "Use the PeoplePicker to manage a group of people"),
React.createElement("li", null, "Use the MemberList PeoplePicker to display selections below the input box"),
React.createElement("li", null, "Use defaultSelectedItems when some people have already been selected"))), donts: React.createElement("div", null,
React.createElement("ul", null,
React.createElement("li", null, "Use the PeoplePicker to select something other than people"),
React.createElement("li", null, "Use the PeoplePicker to only display people"),
React.createElement("li", null, "Use the PeoplePicker without sufficient space"))), componentStatus: React.createElement(ComponentStatus, tslib_1.__assign({}, PeoplePickerStatus)) }));
};
return PeoplePickerPage;
}(React.Component));
export { PeoplePickerPage };
//# sourceMappingURL=PeoplePickerPage.js.map