|
1 | 1 | --- |
2 | 2 | import * as CONFIG from "../../config" |
| 3 | +
|
3 | 4 | const { editHref } = Astro.props |
4 | 5 | const pathname = Astro.url.pathname |
5 | 6 | const section = pathname.split("/").filter(Boolean)[0] |
6 | 7 | const llmsHref = `/${section}/llms-full.txt` |
7 | 8 | const showMoreSection = CONFIG.COMMUNITY_INVITE_URL || editHref |
| 9 | +
|
| 10 | +// ✅ Only show for specific products |
| 11 | +const supportedSections = ["vrf", "ccip", "data-feeds", "data-streams", "chainlink-functions", "chainlink-automation"] |
| 12 | +const llmsExists = supportedSections.includes(section) |
8 | 13 | --- |
9 | 14 |
|
10 | 15 | {showMoreSection && <h2 class="heading">More</h2>} |
11 | 16 | <ul> |
12 | | - <li class="header-link"> |
13 | | - <a href={llmsHref} target="_blank" class="llms-link"> |
14 | | - <svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg"> |
15 | | - <path |
16 | | - fill-rule="evenodd" |
17 | | - clip-rule="evenodd" |
18 | | - d="M12.06 2.06L13 0L13.94 2.06L16 3L13.94 3.94L13 6L12.06 3.94L10 3L12.06 2.06ZM4.47 7.47L6.5 3L8.53 7.47L13 9.5L8.53 11.53L6.5 16L4.47 11.53L0 9.5L4.47 7.47Z" |
19 | | - fill="#0847F7"></path> |
20 | | - </svg> |
21 | | - <p>View as plain text for LLMs</p> |
22 | | - </a> |
23 | | - <svg width="34" height="18" viewBox="0 0 34 18" fill="none" xmlns="http://www.w3.org/2000/svg"> |
24 | | - <path |
25 | | - d="M25 0C29.9706 2.57702e-07 34 4.02944 34 9C34 13.9706 29.9706 18 25 18H9C4.02944 18 0 13.9706 0 9C0 4.02944 4.02944 2.57702e-07 9 0H25ZM7 6V11.8184H7.87793V7.55078H7.93164L10.8896 11.8184H11.6963V6H10.8271V10.2725H10.7725L7.8125 6H7ZM14.0771 6V11.8184H17.7588V11.0625H14.9541V9.28125H17.5342V8.52832H14.9541V6.75586H17.7246V6H14.0771ZM19.5225 6L21.1357 11.8184H22.0225L23.2471 7.45996H23.292L24.5166 11.8184H25.4004L27.0166 6H26.0908L24.96 10.5088H24.9062L23.7266 6H22.8125L21.6328 10.5059H21.5791L20.4453 6H19.5225Z" |
26 | | - fill="#0847F7"></path> |
27 | | - </svg> |
28 | | - </li> |
| 17 | + { |
| 18 | + llmsExists && ( |
| 19 | + <li class="header-link"> |
| 20 | + <a href={llmsHref} target="_blank" class="llms-link"> |
| 21 | + <svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg"> |
| 22 | + <path |
| 23 | + fill-rule="evenodd" |
| 24 | + clip-rule="evenodd" |
| 25 | + d="M12.06 2.06L13 0L13.94 2.06L16 3L13.94 3.94L13 6L12.06 3.94L10 3L12.06 2.06ZM4.47 7.47L6.5 3L8.53 7.47L13 9.5L8.53 11.53L6.5 16L4.47 11.53L0 9.5L4.47 7.47Z" |
| 26 | + fill="#0847F7" |
| 27 | + /> |
| 28 | + </svg> |
| 29 | + <p>View as plain text for LLMs</p> |
| 30 | + </a> |
| 31 | + <svg width="34" height="18" viewBox="0 0 34 18" fill="none" xmlns="http://www.w3.org/2000/svg"> |
| 32 | + <path |
| 33 | + d="M25 0C29.9706 2.57702e-07 34 4.02944 34 9C34 13.9706 29.9706 18 25 18H9C4.02944 18 0 13.9706 0 9C0 4.02944 4.02944 2.57702e-07 9 0H25ZM7 6V11.8184H7.87793V7.55078H7.93164L10.8896 11.8184H11.6963V6H10.8271V10.2725H10.7725L7.8125 6H7ZM14.0771 6V11.8184H17.7588V11.0625H14.9541V9.28125H17.5342V8.52832H14.9541V6.75586H17.7246V6H14.0771ZM19.5225 6L21.1357 11.8184H22.0225L23.2471 7.45996H23.292L24.5166 11.8184H25.4004L27.0166 6H26.0908L24.96 10.5088H24.9062L23.7266 6H22.8125L21.6328 10.5059H21.5791L20.4453 6H19.5225Z" |
| 34 | + fill="#0847F7" |
| 35 | + /> |
| 36 | + </svg> |
| 37 | + </li> |
| 38 | + ) |
| 39 | + } |
29 | 40 | { |
30 | 41 | editHref && ( |
31 | 42 | <li class="header-link"> |
|
0 commit comments