UNPKG

@progress/sitefinity-nextjs-sdk

Version:

Provides OOB widgets developed using the Next.js framework, which includes an abstraction layer for Sitefinity communication. Additionally, it offers an expanded API, typings, and tools for further development and integration.

14 lines (13 loc) 999 B
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime"; export function ClassificationDefaultView(props) { const renderSubTaxa = (taxa, show) => { return (taxa && taxa.length > 0 ? _jsx("ul", { children: taxa.map((t, idx) => { const count = show ? `(${t.AppliedTo})` : ''; return (_jsxs("li", { className: "list-unstyled", children: [_jsx("a", { className: "text-decoration-none", href: t.UrlName, children: t.Title }), count, t.SubTaxa && renderSubTaxa(t.SubTaxa, show)] }, idx)); }) }) : null); }; return (_jsx("ul", { ...props.attributes, children: props.items.map((item, idx) => { const count = props.showItemCount ? `(${item.AppliedTo})` : ''; return (_jsxs("li", { className: "list-unstyled", children: [_jsx("a", { className: "text-decoration-none", href: item.UrlName, children: item.Title }), count, item.SubTaxa && renderSubTaxa(item.SubTaxa, props.showItemCount)] }, idx)); }) })); }