Register
Login
Resources
Docs Blog Datasets Glossary Case Studies Tutorials & Webinars
Product
Data Engine LLMs Platform Enterprise
Pricing Explore
Connect to our Discord channel

header.html 6.3 KB

You have to be logged in to leave a comment. Sign In
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
  1. <div class="border-bottom color-border-secondary no-print">
  2. {% unless error == '404' %}
  3. {% include header-notification %}
  4. {% endunless %}
  5. <header class="container-xl px-3 px-md-6 pt-3 pb-2 position-relative d-flex flex-justify-between width-full {% if error == '404' %} d-md-none {% endif %}">
  6. <div class="d-flex flex-items-center d-lg-none" style="z-index: 3;" id="github-logo-mobile" role="banner">
  7. <a href="/{{ currentLanguage }}" aria-hidden="true" tabindex="-1">
  8. {% octicon "mark-github" height="32" class="color-icon-primary" %}
  9. </a>
  10. <a href="/{{ currentLanguage }}" class="h4-mktg color-text-primary no-underline no-wrap pl-2">{% data ui.header.github_docs %}</a>
  11. </div>
  12. <div class="width-full">
  13. <div class="d-inline-block width-full d-md-flex" style="z-index: 1;">
  14. <button class="nav-mobile-burgerIcon float-right mt-1 border-0 d-md-none" type="button" aria-label="Toggle navigation">
  15. <!-- Hamburger icon added with css -->
  16. </button>
  17. <div style="z-index: 2;" class="nav-mobile-dropdown width-full">
  18. <div class="d-md-flex flex-justify-between flex-items-center">
  19. <div class="py-2 py-md-0 d-md-inline-block">
  20. <h4 class="text-mono f5 text-normal color-text-secondary d-md-none">{% data ui.homepage.explore_by_product %}</h4>
  21. <details class="dropdown-withArrow position-relative details details-reset d-md-none close-when-clicked-outside">
  22. <summary class="nav-desktop-productDropdownButton color-text-link py-2" role="button" aria-label="Toggle products list">
  23. <div id="current-product" class="d-flex flex-items-center flex-justify-between" style="padding-top: 2px;">
  24. <!-- Product switcher - GitHub.com, Enterprise Server, etc -->
  25. <!-- 404 and 500 error layouts are not real pages so we need to hardcode the name for those -->
  26. {{ productMap[currentProduct].name }}
  27. <svg class="arrow ml-md-1" width="14px" height="8px" viewBox="0 0 14 8" xml:space="preserve" fill="none" stroke="currentColor"><path d="M1,1l6.2,6L13,1"></path></svg>
  28. </div>
  29. </summary>
  30. <!-- Mobile-only product dropdown -->
  31. <div id="homepages" class="position-md-absolute nav-desktop-productDropdown p-md-4 left-md-n4 top-md-6" style="z-index: 6;">
  32. {% for product in activeProducts %}
  33. <a href="{% unless product.external %}/{{ currentLanguage }}{% endunless %}{{ product.href }}"
  34. {% if product.external %}target="_blank"{% endif %} class="d-block py-2
  35. {% if product.id == currentProduct %}color-text-link text-underline active{% elsif product.id == currentProduct.id %}color-text-link text-underline active{% else %}Link--primary no-underline{% endif %}">
  36. {{ product.name }}
  37. {% if product.external %}
  38. <span class="ml-1"><svg width="9" height="10" viewBox="0 0 9 10" fill="none" xmlns="http://www.w3.org/2000/svg"><path stroke="currentColor" d="M.646 8.789l8-8M8.5 9V1M1 .643h8"/></svg></span>
  39. {% endif %}
  40. </a>
  41. {% endfor %}
  42. </div>
  43. </details>
  44. </div>
  45. <!-- Versions picker that only appears in the header on landing pages -->
  46. {% include header-version-switcher %}
  47. <div class="d-md-inline-block">
  48. <!-- Language picker - 'English', 'Japanese', etc -->
  49. {% if page.languageVariants.length > 0 and error != '404' and !page.hidden %}
  50. <div class="border-top border-md-top-0 py-2 py-md-0 d-md-inline-block">
  51. <details class="dropdown-withArrow position-relative details details-reset mr-md-3 close-when-clicked-outside">
  52. <summary class="py-2 color-text-primary" role="button" aria-label="Toggle languages list">
  53. <div class="d-flex flex-items-center flex-justify-between">
  54. {% if languages[page.languageCode].nativeName %}
  55. {{ languages[page.languageCode].nativeName }} ({{ languages[page.languageCode].name }})
  56. {% else %}
  57. {{ languages[page.languageCode].name }}
  58. {% endif %}
  59. <svg class="arrow ml-md-1" width="14px" height="8px" viewBox="0 0 14 8" xml:space="preserve" fill="none" stroke="currentColor"><path d="M1,1l6.2,6L13,1"></path></svg>
  60. </div>
  61. </summary>
  62. <div id="languages-selector" class="position-md-absolute nav-desktop-langDropdown p-md-4 right-md-n4 top-md-6" style="z-index: 6;">
  63. {% for languageVariant in page.languageVariants %}
  64. {% unless languages[languageVariant.code].wip %}
  65. <a
  66. href="{{ languageVariant.href }}"
  67. class="d-block py-2 no-underline {% if currentPath == languageVariant.href %}active {% else %}Link--primary{% endif %}"
  68. style="white-space: nowrap"
  69. >
  70. {% if languages[languageVariant.code].nativeName %}
  71. {{ languages[languageVariant.code].nativeName }} ({{ languageVariant.name }})
  72. {% else %}
  73. {{ languageVariant.name }}
  74. {% endif %}
  75. </a>
  76. {% endunless %}
  77. {% endfor %}
  78. </div>
  79. </details>
  80. </div>
  81. {% endif %}
  82. <!-- GitHub.com homepage and 404 page has a stylized search; Enterprise homepages do not -->
  83. {% if page.relativePath != 'index.md' and error != '404' %}
  84. <div class="pt-3 pt-md-0 d-md-inline-block ml-md-3 border-top border-md-top-0">
  85. {% include search-form %}
  86. <div id="search-results-container"></div>
  87. <div class="search-overlay-desktop"></div>
  88. </div>
  89. {% endif %}
  90. </div>
  91. </div>
  92. </div>
  93. </div>
  94. </div>
  95. </header>
  96. </div>
Tip!

Press p or to see the previous file or, n or to see the next file

Comments

Loading...