@cimpress/react-components
Version:
React components to support the MCP styleguide
54 lines • 2.4 kB
JavaScript
;
var __importDefault = (this && this.__importDefault) || function (mod) {
return (mod && mod.__esModule) ? mod : { "default": mod };
};
Object.defineProperty(exports, "__esModule", { value: true });
const react_1 = __importDefault(require("react"));
const react_components_1 = require("@cimpress/react-components");
const table_jsx_1 = __importDefault(require("!raw-loader!./table.jsx"));
const table_jsx_2 = __importDefault(require("./table.jsx"));
const TabbedComponentDoc_1 = __importDefault(require("../../shared/TabbedComponentDoc"));
const TableDocs = () => {
const propInfos = [
{
name: 'condensed',
type: 'boolean',
default: '',
description: 'Toggles the condensed styling for the table.',
},
{
name: 'selectable',
type: 'boolean',
default: '',
description: 'Toggles the column of checkboxes that make rows selectable.',
},
{
name: 'keyField',
type: 'string',
default: '_id',
description: 'The unique accessor property in order to render the select field for a particular row.',
},
{
name: 'goToLabelText',
type: 'string',
default: '',
description: "Text to display in the component that allows jumping to specific text. Default: 'Go To'",
},
{
name: 'perPageLabelText',
type: 'string',
default: '',
description: "Text to display for the dropdown controlling page size. Default: 'Per Page'",
},
];
return (react_1.default.createElement(TabbedComponentDoc_1.default, { name: "Table", propInfos: propInfos, remarks: react_1.default.createElement("p", null,
"All other props not enumerated here will be passed to the underlying component -- see the",
' ',
react_1.default.createElement("a", { href: "https://github.com/TanStack/table/tree/v6", target: "_blank", rel: "noopener noreferrer" }, "react-table v6 docs"),
' ',
"to see more options.") },
react_1.default.createElement(table_jsx_2.default, null),
react_1.default.createElement(react_components_1.CodeExample, { code: table_jsx_1.default })));
};
exports.default = TableDocs;
//# sourceMappingURL=index.js.map