mirror of
https://github.com/hwchase17/langchain.git
synced 2025-07-05 20:58:25 +00:00
docs: compact the API Reference links (#21285)
This PR is opinionated. Issue: the `API Reference` sections in the examples hold too much vertical space and make us scroll the page too much. See an [example](https://python.langchain.com/docs/get_started/quickstart/#conversation-retrieval-chain). These sections are **important**. So, the compacting should not make these sections less noticeable. Change: compacting the `API Reference` sections. See the [same example after change applied](https://langchain-j6nya46lf-langchain.vercel.app/docs/get_started/quickstart/#conversation-retrieval-chain). It is more compact and now looks like references (footnotes). Note: I would also change the section style, so it would be more noticeable (maybe to look like the footnotes. Smaller wider font?) --------- Co-authored-by: Bagatur <22008038+baskaryan@users.noreply.github.com> Co-authored-by: Bagatur <baskaryan@gmail.com>
This commit is contained in:
parent
0ea1e89b2c
commit
2416737c5f
@ -16,18 +16,14 @@ function Imports({ imports }) {
|
||||
borderBottomRightRadius: "var(--ifm-code-border-radius)",
|
||||
}}
|
||||
>
|
||||
<h4 style={{ paddingLeft: "0.65rem", marginBottom: "0.45rem" }}>
|
||||
<b style={{ paddingLeft: "0.65rem", marginBottom: "0.45rem", marginRight: "0.5rem" }}>
|
||||
API Reference:
|
||||
</h4>
|
||||
<ul style={{ paddingBottom: "1rem" }}>
|
||||
{imports.map(({ imported, source, docs }) => (
|
||||
<li key={imported}>
|
||||
<a href={docs}>
|
||||
<span>{imported}</span>
|
||||
</a>
|
||||
</li>
|
||||
</b>
|
||||
{imports.map(({ imported, source, docs }, index) => (
|
||||
<span key={imported}>
|
||||
<a href={docs}>{imported}</a>{index < imports.length - 1 ? ' | ' : ''}
|
||||
</span>
|
||||
))}
|
||||
</ul>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user