/**
 * Copyright IBM Corp. 2020, 2026
 *
 * This source code is licensed under the Apache-2.0 license found in the
 * LICENSE file in the root directory of this source tree.
 */

import { __toESM } from "../../../_virtual/_rolldown/runtime.js";
import { require_classnames } from "../../../node_modules/classnames/index.js";
import { pkg } from "../../../settings.js";
import React from "react";
import { TableBody } from "@carbon/react";

//#region src/components/Datagrid/Datagrid/DatagridSimpleBody.tsx
/**
* Copyright IBM Corp. 2024
*
* This source code is licensed under the Apache-2.0 license found in the
* LICENSE file in the root directory of this source tree.
*/
var import_classnames = /* @__PURE__ */ __toESM(require_classnames());
const blockClass = `${pkg.prefix}--datagrid`;
const DatagridSimpleBody = (datagridState) => {
	const { getTableBodyProps, rows, prepareRow } = datagridState;
	return /* @__PURE__ */ React.createElement(TableBody, {
		...getTableBodyProps({ role: void 0 }),
		"aria-live": void 0,
		className: (0, import_classnames.default)(`${blockClass}__simple-body`, getTableBodyProps().className)
	}, rows.map((row) => {
		prepareRow(row);
		const { key } = row.getRowProps();
		return row?.RowRenderer?.({
			...datagridState,
			row,
			key
		});
	}));
};

//#endregion
export { DatagridSimpleBody as default };