import React from "react";
function RenderValues({ values }) {
return (
{values.map((value) => {
return (
-
{value.value}
);
})}
);
}
function RenderAttributes({ attributes }) {
if (attributes.length === 0) {
return (
This element only supports the{" "}
global attributes
.
);
} else {
return (
<>
This element supports the{" "}
global attributes
{" "}
as well as the following element-specific attributes:
{attributes.map((attribute) => {
return (
-
{attribute.name}: {attribute.type}
-
{/* XXX a div tag in the middle of a dd tag!
See https://github.com/mdn/stumptown-renderer/issues/5
*/}
{attribute.values && attribute.values.length && (
)}
);
})}
>
);
}
}
export function Attributes({ attributes }) {
return (
<>
Attributes
>
);
}