@apify/docs-theme 1.0.252 → 1.0.254

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@apify/docs-theme",
3
- "version": "1.0.252",
3
+ "version": "1.0.254",
4
4
  "description": "",
5
5
  "main": "./src/index.js",
6
6
  "files": [
package/src/config.js CHANGED
@@ -20,129 +20,121 @@ const themeConfig = {
20
20
  },
21
21
  items: [
22
22
  {
23
- label: 'Academy',
24
- href: `${absoluteUrl}/academy`,
25
- activeBasePath: 'academy',
23
+ label: 'Get started',
24
+ href: `${absoluteUrl}/get-started`,
25
+ activeBasePath: 'get-started',
26
26
  position: 'left',
27
27
  target: '_self',
28
28
  rel: 'dofollow',
29
29
  },
30
30
  {
31
- label: 'Platform',
32
- href: `${absoluteUrl}/platform`,
33
- className: 'navbar__active',
34
- activeBasePath: 'platform',
31
+ label: 'Actors',
32
+ href: `${absoluteUrl}/actors`,
33
+ activeBasePath: 'actors',
35
34
  position: 'left',
36
35
  target: '_self',
37
36
  rel: 'dofollow',
38
37
  },
39
38
  {
40
- label: 'API',
41
- type: 'dropdown',
42
- to: `${absoluteUrl}/api`,
39
+ label: 'Storage',
40
+ href: `${absoluteUrl}/storage`,
41
+ activeBasePath: 'storage',
42
+ position: 'left',
43
43
  target: '_self',
44
44
  rel: 'dofollow',
45
- activeBasePath: 'api',
45
+ },
46
+ {
47
+ label: 'Proxy',
48
+ href: `${absoluteUrl}/proxy`,
49
+ activeBasePath: 'proxy',
46
50
  position: 'left',
47
- items: [
48
- {
49
- label: 'Reference',
50
- href: `${absoluteUrl}/api/v2`,
51
- target: '_self',
52
- rel: 'dofollow',
53
- },
54
- {
55
- label: 'Client for JavaScript',
56
- href: `${absoluteUrl}/api/client/js/docs`,
57
- target: '_self',
58
- rel: 'dofollow',
59
- },
60
- {
61
- label: 'Client for Python',
62
- href: `${absoluteUrl}/api/client/python/docs`,
63
- target: '_self',
64
- rel: 'dofollow',
65
- },
66
- ],
51
+ target: '_self',
52
+ rel: 'dofollow',
67
53
  },
68
54
  {
69
- label: 'SDK',
70
- type: 'dropdown',
71
- to: `${absoluteUrl}/sdk`,
72
- activeBasePath: 'sdk',
55
+ label: 'Account',
56
+ href: `${absoluteUrl}/account`,
57
+ activeBasePath: 'account',
73
58
  position: 'left',
74
59
  target: '_self',
75
60
  rel: 'dofollow',
76
- items: [
77
- {
78
- label: 'SDK for JavaScript',
79
- href: `${absoluteUrl}/sdk/js/docs/overview`,
80
- target: '_self',
81
- rel: 'dofollow',
82
- },
83
- {
84
- html: 'SDK for Python',
85
- href: `${absoluteUrl}/sdk/python/docs/overview`,
86
- target: '_self',
87
- rel: 'dofollow',
88
- },
89
- ],
90
61
  },
91
62
  {
92
- label: 'CLI',
93
- href: `${absoluteUrl}/cli/docs`,
63
+ label: 'Integrations',
64
+ href: `${absoluteUrl}/integrations`,
65
+ activeBasePath: 'integrations',
94
66
  position: 'left',
95
- activeBasePath: 'cli',
96
67
  target: '_self',
97
68
  rel: 'dofollow',
98
69
  },
99
70
  {
100
- label: 'Open source',
101
- type: 'dropdown',
102
- to: `${absoluteUrl}/open-source`,
103
- activeBasePath: 'open-source',
71
+ label: 'Limits',
72
+ href: `${absoluteUrl}/limits`,
73
+ activeBasePath: 'limits',
74
+ position: 'left',
104
75
  target: '_self',
76
+ rel: 'dofollow',
77
+ },
78
+ {
79
+ label: 'Security',
80
+ href: `${absoluteUrl}/security`,
81
+ activeBasePath: 'security',
105
82
  position: 'left',
106
- className: 'navbar__item',
83
+ target: '_self',
84
+ rel: 'dofollow',
85
+ },
86
+ {
87
+ label: 'Academy',
88
+ href: `${absoluteUrl}/academy`,
89
+ activeBasePath: 'academy',
90
+ position: 'right',
91
+ target: '_self',
92
+ rel: 'dofollow',
93
+ },
94
+ {
95
+ label: 'APIs, SDKs & CLI',
96
+ type: 'dropdown',
97
+ activeBaseRegex: '^/(api|sdk|cli)/',
98
+ position: 'right',
107
99
  items: [
108
100
  {
109
- label: 'Crawlee',
110
- href: 'https://crawlee.dev',
101
+ label: 'API Reference',
102
+ href: `${absoluteUrl}/api/v2`,
103
+ target: '_self',
111
104
  rel: 'dofollow',
112
105
  },
113
106
  {
114
- label: 'Fingerprint Suite',
115
- href: 'https://github.com/apify/fingerprint-suite',
116
- },
117
- {
118
- label: 'impit',
119
- href: 'https://github.com/apify/impit',
107
+ label: 'SDK for JavaScript',
108
+ href: `${absoluteUrl}/sdk/js/docs/overview`,
109
+ target: '_self',
110
+ rel: 'dofollow',
120
111
  },
121
112
  {
122
- label: 'MCP CLI',
123
- href: 'https://github.com/apify/mcpc',
113
+ label: 'SDK for Python',
114
+ href: `${absoluteUrl}/sdk/python/docs/overview`,
115
+ target: '_self',
116
+ rel: 'dofollow',
124
117
  },
125
118
  {
126
- label: 'Actor whitepaper',
127
- href: 'https://whitepaper.actor',
119
+ label: 'Client for JavaScript',
120
+ href: `${absoluteUrl}/api/client/js/docs`,
121
+ target: '_self',
122
+ rel: 'dofollow',
128
123
  },
129
124
  {
130
- label: 'proxy-chain',
131
- href: 'https://github.com/apify/proxy-chain',
125
+ label: 'Client for Python',
126
+ href: `${absoluteUrl}/api/client/python/docs`,
127
+ target: '_self',
128
+ rel: 'dofollow',
132
129
  },
133
130
  {
134
- label: 'Apify on GitHub',
135
- href: 'https://github.com/apify',
131
+ label: 'CLI',
132
+ href: `${absoluteUrl}/cli/docs`,
133
+ target: '_self',
134
+ rel: 'dofollow',
136
135
  },
137
136
  ],
138
137
  },
139
- {
140
- href: 'https://discord.com/invite/jyEM2PRvMU',
141
- label: 'Discord',
142
- title: 'Chat on Discord',
143
- position: 'right',
144
- className: 'icon',
145
- },
146
138
  ],
147
139
  },
148
140
  colorMode: {
@@ -170,8 +162,14 @@ const themeConfig = {
170
162
  rel: 'dofollow',
171
163
  },
172
164
  {
173
- label: 'Platform',
174
- href: `${absoluteUrl}/platform`,
165
+ label: 'Get started',
166
+ href: `${absoluteUrl}/get-started`,
167
+ target: '_self',
168
+ rel: 'dofollow',
169
+ },
170
+ {
171
+ label: 'Actors',
172
+ href: `${absoluteUrl}/actors`,
175
173
  target: '_self',
176
174
  rel: 'dofollow',
177
175
  },
@@ -218,18 +216,45 @@ const themeConfig = {
218
216
  ],
219
217
  },
220
218
  {
221
- title: 'Other',
219
+ title: 'Open source',
222
220
  items: [
223
221
  {
224
- label: 'CLI',
225
- href: `${absoluteUrl}/cli/docs`,
226
- position: 'left',
227
- target: '_self',
222
+ label: 'Crawlee',
223
+ href: 'https://crawlee.dev',
228
224
  rel: 'dofollow',
229
225
  },
230
226
  {
231
- label: 'Open source',
232
- href: `${absoluteUrl}/open-source`,
227
+ label: 'Fingerprint Suite',
228
+ href: 'https://github.com/apify/fingerprint-suite',
229
+ },
230
+ {
231
+ label: 'impit',
232
+ href: 'https://github.com/apify/impit',
233
+ },
234
+ {
235
+ label: 'MCP CLI',
236
+ href: 'https://github.com/apify/mcpc',
237
+ },
238
+ {
239
+ label: 'Actor whitepaper',
240
+ href: 'https://whitepaper.actor',
241
+ },
242
+ {
243
+ label: 'proxy-chain',
244
+ href: 'https://github.com/apify/proxy-chain',
245
+ },
246
+ {
247
+ label: 'Apify on GitHub',
248
+ href: 'https://github.com/apify',
249
+ },
250
+ ],
251
+ },
252
+ {
253
+ title: 'Other',
254
+ items: [
255
+ {
256
+ label: 'CLI',
257
+ href: `${absoluteUrl}/cli/docs`,
233
258
  position: 'left',
234
259
  target: '_self',
235
260
  rel: 'dofollow',
@@ -51,7 +51,14 @@ export default function DocItemContent({ children }) {
51
51
  '/api/v2/logs',
52
52
  '/api/v2/users',
53
53
  '/api/client',
54
- '/platform',
54
+ '/get-started',
55
+ '/actors',
56
+ '/storage',
57
+ '/proxy',
58
+ '/account',
59
+ '/integrations',
60
+ '/limits',
61
+ '/security',
55
62
  '/sdk',
56
63
  '/cli',
57
64
  '/academy',
@@ -1,6 +1,6 @@
1
1
  import styles from './styles.module.css';
2
2
 
3
- const buttonText = 'Go to Console';
3
+ const buttonText = 'Get started';
4
4
 
5
5
  function clickHandler() {
6
6
  if (window.analytics) {
@@ -0,0 +1,10 @@
1
+ export function DiscordIcon({ color = 'currentColor', size = 24 }) {
2
+ return (
3
+ <svg width={size} height={size} viewBox="100 195 800 625" xmlns="http://www.w3.org/2000/svg">
4
+ <path
5
+ fill={color}
6
+ d="M386 203h2l7 9c-128 36-186 92-186 92s15-8 41-20c76-34 136-43 161-45 4-1 8-1 12-1 43-6 92-7 143-2 67 8 139 28 213 68 0 0-56-53-176-90l9-11s97-2 199 74c0 0 102 185 102 412 0 0-60 103-216 108 0 0-26-30-47-57 93-26 128-84 128-84-29 19-57 32-81 41-36 15-70 25-103 31-68 12-130 9-183-1-40-8-75-19-104-30-16-7-34-15-52-24-2-2-4-3-6-4-1-1-2-1-3-2-13-7-20-12-20-12s34 56 124 83c-21 27-47 59-47 59-157-5-216-108-216-108 0-227 102-412 102-412 95-71 186-74 197-74m-18 264c-41 0-72 35-72 78s32 79 72 79 72-36 72-79c1-43-32-78-72-78m258 0c-40 0-72 35-72 78s32 79 72 79 72-36 72-79-32-78-72-78"
7
+ />
8
+ </svg>
9
+ );
10
+ }
@@ -11,6 +11,7 @@ import React from 'react';
11
11
 
12
12
  // import SearchBar from '../../SearchBar';
13
13
  import NavbarCTA from '../CTA';
14
+ import { DiscordIcon } from './DiscordIcon';
14
15
 
15
16
  function NavbarItems({ items }) {
16
17
  return (
@@ -22,11 +23,12 @@ function NavbarItems({ items }) {
22
23
  );
23
24
  }
24
25
 
25
- function NavbarContentLayout({ left, right }) {
26
+ function NavbarContentLayout({ left, center, right }) {
26
27
  return (
27
28
  <div className="navbar__inner">
28
29
  <div className="navbar__container">
29
30
  <div className="navbar__items">{left}</div>
31
+ <div className="navbar__items navbar__items--center">{center}</div>
30
32
  <div className="navbar__items navbar__items--right">{right}</div>
31
33
  </div>
32
34
  </div>
@@ -88,22 +90,42 @@ export default function NavbarContent() {
88
90
  left={
89
91
  <>
90
92
  <NavbarLogo />
91
- <NavbarItems items={leftItems} />
92
93
  </>
93
94
  }
95
+ center={
96
+ !searchBarItem && (
97
+ <NavbarSearch>
98
+ <SearchBar />
99
+ </NavbarSearch>
100
+ )
101
+ }
94
102
  right={
95
103
  <>
96
- <NavbarItems items={rightItems} />
97
- {!searchBarItem && (
98
- <NavbarSearch>
99
- <SearchBar />
100
- </NavbarSearch>
101
- )}
104
+ <a
105
+ href="https://discord.com/invite/jyEM2PRvMU"
106
+ className="icon"
107
+ target="_blank"
108
+ rel="noopener noreferrer"
109
+ >
110
+ <DiscordIcon size={20} />
111
+ </a>
102
112
  <NavbarCTA />
103
113
  <NavbarMobileSidebarToggle />
104
114
  </>
105
115
  }
106
116
  />
117
+ <NavbarContentLayout
118
+ left={
119
+ <>
120
+ <NavbarItems items={leftItems} />
121
+ </>
122
+ }
123
+ right={
124
+ <>
125
+ <NavbarItems items={rightItems} />
126
+ </>
127
+ }
128
+ />
107
129
  <SubNavbar />
108
130
  </div>
109
131
  );
@@ -0,0 +1,20 @@
1
+ export function SparklesIcon({ color = 'currentColor', size = 16 }) {
2
+ return (
3
+ <svg
4
+ width={size}
5
+ height={size}
6
+ viewBox="0 0 16 15"
7
+ fill="none"
8
+ xmlns="http://www.w3.org/2000/svg"
9
+ aria-hidden="true"
10
+ >
11
+ <path
12
+ d="M11.6673 12.5007C12.1093 12.5007 12.5333 12.6762 12.8458 12.9888C13.1584 13.3014 13.334 13.7253 13.334 14.1673C13.334 13.7253 13.5096 13.3014 13.8221 12.9888C14.1347 12.6762 14.5586 12.5007 15.0007 12.5007C14.5586 12.5007 14.1347 12.3251 13.8221 12.0125C13.5096 11.6999 13.334 11.276 13.334 10.834C13.334 11.276 13.1584 11.6999 12.8458 12.0125C12.5333 12.3251 12.1093 12.5007 11.6673 12.5007ZM11.6673 2.50065C12.1093 2.50065 12.5333 2.67625 12.8458 2.98881C13.1584 3.30137 13.334 3.72529 13.334 4.16732C13.334 3.72529 13.5096 3.30137 13.8221 2.98881C14.1347 2.67625 14.5586 2.50065 15.0007 2.50065C14.5586 2.50065 14.1347 2.32506 13.8221 2.0125C13.5096 1.69994 13.334 1.27601 13.334 0.833984C13.334 1.27601 13.1584 1.69994 12.8458 2.0125C12.5333 2.32506 12.1093 2.50065 11.6673 2.50065ZM5.83398 12.5007C5.83398 11.1746 6.36077 9.9028 7.29845 8.96512C8.23613 8.02744 9.5079 7.50065 10.834 7.50065C9.5079 7.50065 8.23613 6.97387 7.29845 6.03618C6.36077 5.0985 5.83398 3.82673 5.83398 2.50065C5.83398 3.82673 5.3072 5.0985 4.36952 6.03618C3.43184 6.97387 2.16007 7.50065 0.833984 7.50065C2.16007 7.50065 3.43184 8.02744 4.36952 8.96512C5.3072 9.9028 5.83398 11.1746 5.83398 12.5007Z"
13
+ stroke={color}
14
+ strokeWidth="1.66667"
15
+ strokeLinecap="round"
16
+ strokeLinejoin="round"
17
+ />
18
+ </svg>
19
+ );
20
+ }
@@ -6,6 +6,7 @@ import useDocusaurusContext from '@docusaurus/useDocusaurusContext';
6
6
  import { useState, useCallback } from 'react';
7
7
 
8
8
  import { ApifySearch } from '@apify/docs-search-modal';
9
+ import { SparklesIcon } from './SparklesIcon';
9
10
 
10
11
  // needs to be imported as the last thing, so that it can override the default styles
11
12
  // TODO: update simple-import-sort to allow importing css as last.
@@ -16,7 +17,17 @@ import './styles.css';
16
17
  */
17
18
  function matchesCurrentInstance(href, baseUrl) {
18
19
  if (baseUrl === '/') {
19
- return href.startsWith('/academy') || href.startsWith('/platform');
20
+ return (
21
+ href.startsWith('/academy') ||
22
+ href.startsWith('/get-started') ||
23
+ href.startsWith('/actors') ||
24
+ href.startsWith('/storage') ||
25
+ href.startsWith('/proxy') ||
26
+ href.startsWith('/account') ||
27
+ href.startsWith('/integrations') ||
28
+ href.startsWith('/limits') ||
29
+ href.startsWith('/security')
30
+ );
20
31
  }
21
32
 
22
33
  return href.startsWith(baseUrl);
@@ -106,6 +117,7 @@ function KapaAIButton({ onClick }) {
106
117
  {() => (
107
118
  <div onClick={onClick}>
108
119
  <button type="button" className="AskAI-Button" aria-label="Ask AI">
120
+ <SparklesIcon size={14} />
109
121
  Ask AI
110
122
  </button>
111
123
  </div>
@@ -26,19 +26,20 @@
26
26
  .AskAI-Button {
27
27
  height: 4rem;
28
28
  padding: 0.8rem 1.6rem !important;
29
- background-color: var(--ifm-color-primary);
29
+ background-color: rgba(255, 255, 255, 0);
30
30
  border-radius: 8px;
31
- color: var(--color-neutral-text-on-primary);
32
31
  font-family: inherit;
33
32
  font-size: 1.6rem;
34
- font-weight: 500;
33
+ font-weight: 400;
35
34
  line-height: 2.4rem;
36
- border: none;
35
+ border: 1px solid var(--color-neutral-border);
37
36
  box-shadow: none;
38
37
  outline: none;
39
38
  box-sizing: border-box;
40
39
  cursor: pointer;
41
- display: block;
40
+ display: flex;
41
+ align-items: center;
42
+ gap: 0.6rem;
42
43
  position: relative;
43
44
  text-align: center;
44
45
  transition: all var(--ifm-transition-fast) var(--ifm-transition-timing-default);
@@ -53,6 +54,12 @@
53
54
  display: none;
54
55
  }
55
56
 
57
+ @media (min-width: 769px) {
58
+ .DocSearch-Button {
59
+ width: 30rem;
60
+ }
61
+ }
62
+
56
63
  @media (max-width: 768px) {
57
64
  .SearchButton-Container {
58
65
  width: 100%;
@@ -551,34 +551,16 @@ aside > div > a > b {
551
551
  top: 10px;
552
552
  }
553
553
 
554
- .navbar .icon {
555
- font-size: 0;
556
- padding: 4px;
557
- line-height: 0;
558
- }
559
-
560
- .navbar .icon::before {
561
- content: '';
562
- display: block;
563
- width: 24px;
564
- height: 24px;
565
- background-size: cover;
566
- }
567
-
568
- .navbar .icon[href*='github']::before {
569
- background-image: url('/img/github-brand.svg');
570
- }
571
-
572
- html[data-theme='dark'] .navbar .navbar__link[href*='github']:before {
573
- background-image: url('/img/github-brand-dark.svg');
574
- }
575
-
576
- .navbar .icon[href*='discord']::before {
577
- background-image: url('/img/discord-brand.svg');
578
- }
579
-
580
- html[data-theme='dark'] .navbar .navbar__link[href*='discord']:before {
581
- background-image: url('/img/discord-brand-dark.svg');
554
+ .navbar .icon[href*='discord'] {
555
+ display: flex;
556
+ align-items: center;
557
+ justify-content: center;
558
+ width: 4rem;
559
+ height: 4rem;
560
+ background-color: var(--color-Neutral_BackgroundMuted);
561
+ border: 1px solid var(--color-neutral-border);
562
+ border-radius: 4px;
563
+ color: var(--ifm-navbar-link-color);
582
564
  }
583
565
 
584
566
  .navbar .icon svg[class*='iconExternalLink'],
@@ -1,3 +0,0 @@
1
- <svg width="80" height="80" viewBox="0 0 1000 1000" xmlns="http://www.w3.org/2000/svg">
2
- <path fill="#F5F6F7" d="M500 0C224 0 0 224 0 500s224 500 500 500 500-224 500-500S776 0 500 0M386 203h2l7 9c-128 36-186 92-186 92s15-8 41-20c76-34 136-43 161-45 4-1 8-1 12-1 43-6 92-7 143-2 67 8 139 28 213 68 0 0-56-53-176-90l9-11s97-2 199 74c0 0 102 185 102 412 0 0-60 103-216 108 0 0-26-30-47-57 93-26 128-84 128-84-29 19-57 32-81 41-36 15-70 25-103 31-68 12-130 9-183-1-40-8-75-19-104-30-16-7-34-15-52-24-2-2-4-3-6-4-1-1-2-1-3-2-13-7-20-12-20-12s34 56 124 83c-21 27-47 59-47 59-157-5-216-108-216-108 0-227 102-412 102-412 95-71 186-74 197-74m-18 264c-41 0-72 35-72 78s32 79 72 79 72-36 72-79c1-43-32-78-72-78m258 0c-40 0-72 35-72 78s32 79 72 79 72-36 72-79-32-78-72-78"/>
3
- </svg>
@@ -1,3 +0,0 @@
1
- <svg width="80" height="80" viewBox="0 0 1000 1000" xmlns="http://www.w3.org/2000/svg">
2
- <path fill="#333" d="M500 0C224 0 0 224 0 500s224 500 500 500 500-224 500-500S776 0 500 0M386 203h2l7 9c-128 36-186 92-186 92s15-8 41-20c76-34 136-43 161-45 4-1 8-1 12-1 43-6 92-7 143-2 67 8 139 28 213 68 0 0-56-53-176-90l9-11s97-2 199 74c0 0 102 185 102 412 0 0-60 103-216 108 0 0-26-30-47-57 93-26 128-84 128-84-29 19-57 32-81 41-36 15-70 25-103 31-68 12-130 9-183-1-40-8-75-19-104-30-16-7-34-15-52-24-2-2-4-3-6-4-1-1-2-1-3-2-13-7-20-12-20-12s34 56 124 83c-21 27-47 59-47 59-157-5-216-108-216-108 0-227 102-412 102-412 95-71 186-74 197-74m-18 264c-41 0-72 35-72 78s32 79 72 79 72-36 72-79c1-43-32-78-72-78m258 0c-40 0-72 35-72 78s32 79 72 79 72-36 72-79-32-78-72-78"/>
3
- </svg>