silverwolf-x's picture
download
raw
1.48 kB
import React from "react";
import {
ComponentParams,
ComponentRendering,
Placeholder,
} from "@sitecore-jss/sitecore-jss-nextjs";
interface ComponentProps {
rendering: ComponentRendering & { params: ComponentParams };
params: ComponentParams;
}
export const Default = (props: ComponentProps): JSX.Element => {
const styles = `${props.params.GridParameters ?? ""} ${
props.params.Styles ?? ""
}`.trimEnd();
const rowStyles = [
props.params.Styles1,
props.params.Styles2,
props.params.Styles3,
props.params.Styles4,
props.params.Styles5,
props.params.Styles6,
props.params.Styles7,
props.params.Styles8,
];
const enabledPlaceholders = props.params.EnabledPlaceholders.split(",");
const id = props.params.RenderingIdentifier;
return (
<div
className={`component row-splitter ${styles}`}
id={id ? id : undefined}
>
{enabledPlaceholders.map((ph, index) => {
const phKey = `row-${ph}-{*}`;
const phStyles = `${rowStyles[+ph - 1] ?? ""}`.trimEnd();
return (
<div key={index} className={`container-fluid ${phStyles}`.trimEnd()}>
<div key={index}>
<div key={index} className="row">
<Placeholder
key={index}
name={phKey}
rendering={props.rendering}
/>
</div>
</div>
</div>
);
})}
</div>
);
};

Xet Storage Details

Size:
1.48 kB
·
Xet hash:
b225263c425597e8583e35db4bf262b7f9cd78347987ba8ec57038511493e22f

Xet efficiently stores files, intelligently splitting them into unique chunks and accelerating uploads and downloads. More info.