@theguild/components 7.2.0-alpha-20241101220642-0b6682d9cf4196529799e8ad0e38b83426590e93 → 8.0.0-alpha-20241103132221-f9d255adde945cffb98f9f7c914ac29896a15819

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.
Files changed (117) hide show
  1. package/dist/chunk-ME7V4BHY.js +10 -0
  2. package/dist/cn.d.mts +5 -0
  3. package/dist/cn.js +8 -0
  4. package/dist/components/anchor.d.mts +11 -0
  5. package/dist/components/anchor.js +30 -0
  6. package/dist/components/button.d.mts +13 -0
  7. package/dist/components/button.js +25 -0
  8. package/dist/components/call-to-action.d.mts +38 -0
  9. package/dist/components/call-to-action.js +42 -0
  10. package/dist/components/cards-colorful.d.mts +19 -0
  11. package/dist/components/cards-colorful.js +20 -0
  12. package/dist/components/cookies-consent.d.mts +7 -0
  13. package/dist/components/cookies-consent.js +48 -0
  14. package/dist/components/decorations/index.d.mts +11 -0
  15. package/dist/components/decorations/index.js +72 -0
  16. package/dist/components/feature-list.d.mts +9 -0
  17. package/dist/components/feature-list.js +41 -0
  18. package/dist/components/footer.d.mts +9 -0
  19. package/dist/components/footer.js +116 -0
  20. package/dist/components/get-your-api-game-right-section.d.mts +7 -0
  21. package/dist/components/get-your-api-game-right-section.js +122 -0
  22. package/dist/components/giscus.d.mts +6 -0
  23. package/dist/components/giscus.js +14 -0
  24. package/dist/components/guild-navbar-logo.d.mts +19 -0
  25. package/dist/components/guild-navbar-logo.js +62 -0
  26. package/dist/components/heading.d.mts +10 -0
  27. package/dist/components/heading.js +36 -0
  28. package/dist/components/hero-gradient.d.mts +9 -0
  29. package/dist/components/hero-gradient.js +82 -0
  30. package/dist/components/hero-illustration.d.mts +9 -0
  31. package/dist/components/hero-illustration.js +31 -0
  32. package/dist/components/hero-marketplace.d.mts +9 -0
  33. package/dist/components/hero-marketplace.js +78 -0
  34. package/dist/components/hero-video.d.mts +9 -0
  35. package/dist/components/hero-video.js +73 -0
  36. package/dist/components/hive-footer.d.mts +11 -0
  37. package/dist/components/hive-footer.js +252 -0
  38. package/dist/components/hive-navigation/graphql-conf-card.d.mts +9 -0
  39. package/dist/components/hive-navigation/graphql-conf-card.js +26 -0
  40. package/dist/components/hive-navigation/index.d.mts +55 -0
  41. package/dist/components/hive-navigation/index.js +392 -0
  42. package/dist/components/hive-navigation/navigation-menu.d.mts +23 -0
  43. package/dist/components/hive-navigation/navigation-menu.js +179 -0
  44. package/dist/components/icons/index.d.mts +6 -0
  45. package/dist/{chunk-XKCA3AB7.js → components/icons/index.js} +29 -266
  46. package/dist/components/image.d.mts +6 -0
  47. package/dist/components/image.js +8 -0
  48. package/dist/components/index.d.mts +44 -0
  49. package/dist/components/index.js +52 -0
  50. package/dist/components/info-card.d.mts +11 -0
  51. package/dist/components/info-card.js +20 -0
  52. package/dist/components/info-list.d.mts +9 -0
  53. package/dist/components/info-list.js +27 -0
  54. package/dist/components/legacy-package-cmd.d.mts +13 -0
  55. package/dist/components/legacy-package-cmd.js +54 -0
  56. package/dist/components/marketplace-list.d.mts +9 -0
  57. package/dist/components/marketplace-list.js +118 -0
  58. package/dist/components/marketplace-search.d.mts +9 -0
  59. package/dist/components/marketplace-search.js +111 -0
  60. package/dist/components/npm-badge.d.mts +7 -0
  61. package/dist/components/npm-badge.js +16 -0
  62. package/dist/components/schema-type.d.mts +9 -0
  63. package/dist/components/schema-type.js +80 -0
  64. package/dist/components/stud.d.mts +7 -0
  65. package/dist/components/stud.js +17 -0
  66. package/dist/components/tag.d.mts +13 -0
  67. package/dist/components/tag.js +26 -0
  68. package/dist/components/theme-switcher.d.mts +7 -0
  69. package/dist/components/theme-switcher.js +17 -0
  70. package/dist/components/tools-and-libraries-cards.d.mts +7 -0
  71. package/dist/components/tools-and-libraries-cards.js +442 -0
  72. package/dist/constants.d.mts +7 -0
  73. package/dist/constants.js +7 -0
  74. package/dist/helpers/render-slot.d.mts +3 -0
  75. package/dist/helpers/render-slot.js +21 -0
  76. package/dist/index.d.mts +64 -339
  77. package/dist/index.js +21 -3115
  78. package/dist/logos/index.d.mts +26 -0
  79. package/dist/{chunk-EWF5AT2G.js → logos/index.js} +68 -53
  80. package/dist/mdx-components.d.mts +5 -0
  81. package/dist/mdx-components.js +50 -0
  82. package/dist/products.d.mts +10 -5
  83. package/dist/products.js +230 -5
  84. package/dist/server/index.d.mts +5 -0
  85. package/dist/server/index.js +12 -0
  86. package/dist/server/next.config.d.mts +10 -0
  87. package/dist/server/next.config.js +107 -0
  88. package/dist/server/npm.d.mts +21 -0
  89. package/dist/server/npm.js +75 -0
  90. package/dist/server/package.json +1 -0
  91. package/dist/server/pages.d.mts +1 -0
  92. package/dist/server/pages.js +5 -0
  93. package/dist/server/underscore-redirects.d.mts +3 -0
  94. package/dist/server/underscore-redirects.js +40 -0
  95. package/dist/static/illustrations/marketplace-cube-bl.d.mts +2 -0
  96. package/dist/static/illustrations/marketplace-cube-br.d.mts +2 -0
  97. package/dist/static/illustrations/marketplace-cube-tl.d.mts +2 -0
  98. package/dist/static/illustrations/marketplace-cube-tr.d.mts +2 -0
  99. package/dist/static/illustrations/marketplace-desktop.d.mts +2 -0
  100. package/dist/static/illustrations/marketplace-mobile.d.mts +2 -0
  101. package/dist/theme-layout.d.mts +39 -0
  102. package/dist/theme-layout.js +144 -0
  103. package/dist/types/components.d.mts +121 -0
  104. package/dist/types/components.js +0 -0
  105. package/package.json +19 -36
  106. package/style.css +10 -8
  107. package/dist/compile.mjs +0 -11
  108. package/dist/index.css +0 -133
  109. package/dist/logos.d.mts +0 -32
  110. package/dist/logos.js +0 -54
  111. package/dist/next.config.mjs +0 -135
  112. /package/dist/{marketplace-cube-bl-42X7Y3KO.png → static/illustrations/marketplace-cube-bl.png} +0 -0
  113. /package/dist/{marketplace-cube-br-Y5MZRDIL.png → static/illustrations/marketplace-cube-br.png} +0 -0
  114. /package/dist/{marketplace-cube-tl-PEJKW6RX.png → static/illustrations/marketplace-cube-tl.png} +0 -0
  115. /package/dist/{marketplace-cube-tr-O5XQ6Q4N.png → static/illustrations/marketplace-cube-tr.png} +0 -0
  116. /package/dist/{marketplace-desktop-7XUR54PR.png → static/illustrations/marketplace-desktop.png} +0 -0
  117. /package/dist/{marketplace-mobile-DI462WKF.png → static/illustrations/marketplace-mobile.png} +0 -0
package/dist/index.css DELETED
@@ -1,133 +0,0 @@
1
- /* src/components/marketplace-search.css */
2
- .MarketplaceSearch {
3
- --fg: #fff;
4
- --fg-80: rgb(from var(--fg) r g b / 0.8);
5
- --fg-70: rgb(from var(--fg) r g b / 0.7);
6
- --fg-60: rgb(from var(--fg) r g b / 0.6);
7
- &.green {
8
- --bg: #00342C;
9
- }
10
- &.neutral {
11
- --bg: #171717;
12
- .light & {
13
- --bg: #fff;
14
- --fg: #171717;
15
- }
16
- }
17
- }
18
- .MarketplaceSearchTabs [role=tablist] {
19
- display: grid;
20
- grid-template-columns: repeat(2, minmax(0, 1fr));
21
- gap: 0.25rem;
22
- border-radius: 1rem;
23
- border-style: none;
24
- --tw-bg-opacity: 1;
25
- background-color: rgb(38 38 38 / var(--tw-bg-opacity));
26
- }
27
- .MarketplaceSearchTabs [role=tablist].green {
28
- --tw-bg-opacity: 1;
29
- background-color: rgb(21 67 60 / var(--tw-bg-opacity));
30
- }
31
- .MarketplaceSearchTabs [role=tablist] {
32
- .light & {
33
- --tw-bg-opacity: 1;
34
- background-color: rgb(245 245 245 / var(--tw-bg-opacity));
35
- }
36
- .green & {
37
- --tw-bg-opacity: 1;
38
- background-color: rgb(21 67 60 / var(--tw-bg-opacity));
39
- }
40
- & button {
41
- border-radius: 1rem;
42
- }
43
- & button {
44
- border-style: none;
45
- }
46
- & button {
47
- padding: 0.75rem;
48
- }
49
- & button {
50
- font-size: .875rem;
51
- }
52
- & button {
53
- font-weight: 500;
54
- }
55
- & button {
56
- --tw-text-opacity: 1;
57
- color: rgb(229 229 229 / var(--tw-text-opacity));
58
- }
59
- @media (min-width: 640px) {
60
- & button {
61
- padding: 1rem;
62
- }
63
- }
64
- @media (min-width: 640px) {
65
- & button {
66
- font-size: 1rem;
67
- }
68
- }
69
- & button {
70
- .light & {
71
- --tw-bg-opacity: 1;
72
- background-color: rgb(245 245 245 / var(--tw-bg-opacity));
73
- }
74
- .light & {
75
- --tw-text-opacity: 1;
76
- color: rgb(38 38 38 / var(--tw-text-opacity));
77
- }
78
- .green & {
79
- --tw-bg-opacity: 1;
80
- background-color: rgb(21 67 60 / var(--tw-bg-opacity));
81
- }
82
- .green & {
83
- --tw-text-opacity: 1;
84
- color: rgb(202 228 222 / var(--tw-text-opacity));
85
- }
86
- &:hover {
87
- background-color: rgb(64 64 64 / 0.5);
88
- }
89
- &:hover {
90
- --tw-text-opacity: 1;
91
- color: rgb(255 255 255 / var(--tw-text-opacity));
92
- }
93
- &:hover {
94
- .light & {
95
- background-color: rgb(229 229 229 / 0.8);
96
- }
97
- .light & {
98
- --tw-text-opacity: 1;
99
- color: rgb(23 23 23 / var(--tw-text-opacity));
100
- }
101
- .green & {
102
- background-color: rgb(59 115 106 / 0.25);
103
- }
104
- .green & {
105
- --tw-text-opacity: 1;
106
- color: rgb(236 246 243 / var(--tw-text-opacity));
107
- }
108
- }
109
- &[aria-selected=true],
110
- &[aria-selected=true]:hover {
111
- cursor: default;
112
- }
113
- &[aria-selected=true],
114
- &[aria-selected=true]:hover {
115
- background-color: var(--fg);
116
- }
117
- &[aria-selected=true],
118
- &[aria-selected=true]:hover {
119
- color: var(--bg);
120
- }
121
- &[aria-selected=true],
122
- &[aria-selected=true]:hover {
123
- .green & {
124
- --tw-bg-opacity: 1;
125
- background-color: rgb(167 213 202 / var(--tw-bg-opacity));
126
- }
127
- .green & {
128
- --tw-text-opacity: 1;
129
- color: rgb(36 88 80 / var(--tw-text-opacity));
130
- }
131
- }
132
- }
133
- }
package/dist/logos.d.mts DELETED
@@ -1,32 +0,0 @@
1
- import * as react_jsx_runtime from 'react/jsx-runtime';
2
- import { FC, SVGProps, HTMLAttributes } from 'react';
3
-
4
- // eslint-disable-next-line @typescript-eslint/no-restricted-imports
5
-
6
-
7
- declare const ReactComponent: FC<SVGProps<SVGElement>>;
8
-
9
- interface LettermarkLogoProps extends HTMLAttributes<HTMLElement> {
10
- }
11
- declare const InspectorLettermark: {
12
- (props: LettermarkLogoProps): react_jsx_runtime.JSX.Element;
13
- displayName: string;
14
- };
15
- declare const SofaLettermark: {
16
- (props: LettermarkLogoProps): react_jsx_runtime.JSX.Element;
17
- displayName: string;
18
- };
19
- declare const GraphQLESlintLettermark: {
20
- (props: LettermarkLogoProps): react_jsx_runtime.JSX.Element;
21
- displayName: string;
22
- };
23
- declare const EnvelopLettermark: {
24
- (props: LettermarkLogoProps): react_jsx_runtime.JSX.Element;
25
- displayName: string;
26
- };
27
- declare const ScalarsLettermark: {
28
- (props: LettermarkLogoProps): react_jsx_runtime.JSX.Element;
29
- displayName: string;
30
- };
31
-
32
- export { ReactComponent as AngularLogo, ReactComponent as CodeGeneratorLogo, ReactComponent as ConductorLogo, ReactComponent as ConfigLogo, EnvelopLettermark, ReactComponent as FetsLogo, GraphQLESlintLettermark, ReactComponent as GraphQLFoundationLogo, ReactComponent as GuildLogo, ReactComponent as HeltinLogo, ReactComponent as HiveCombinationMark, InspectorLettermark, ReactComponent as KitQLLogo, type LettermarkLogoProps, ReactComponent as MeshLogo, ReactComponent as ModulesLogo, ReactComponent as NextraLogo, ReactComponent as SSELogo, ScalarsLettermark, SofaLettermark, ReactComponent as StitchingLogo, ReactComponent as TheGuild, ReactComponent as ToolsLogo, ReactComponent as WSLogo, ReactComponent as WhatsAppLogo, ReactComponent as YogaLogo };
package/dist/logos.js DELETED
@@ -1,54 +0,0 @@
1
- import {
2
- EnvelopLettermark,
3
- GraphQLESlintLettermark,
4
- InspectorLettermark,
5
- ScalarsLettermark,
6
- SofaLettermark,
7
- SvgAngular,
8
- SvgCodeGenerator,
9
- SvgConductor,
10
- SvgConfig,
11
- SvgFets,
12
- SvgGraphqlFoundation,
13
- SvgGuild,
14
- SvgHeltin,
15
- SvgHiveCombinationMark,
16
- SvgKitql,
17
- SvgMesh,
18
- SvgModules,
19
- SvgNextra,
20
- SvgSse,
21
- SvgStitching,
22
- SvgTheGuild,
23
- SvgTools,
24
- SvgWhatsapp,
25
- SvgWs,
26
- SvgYoga
27
- } from "./chunk-EWF5AT2G.js";
28
- export {
29
- SvgAngular as AngularLogo,
30
- SvgCodeGenerator as CodeGeneratorLogo,
31
- SvgConductor as ConductorLogo,
32
- SvgConfig as ConfigLogo,
33
- EnvelopLettermark,
34
- SvgFets as FetsLogo,
35
- GraphQLESlintLettermark,
36
- SvgGraphqlFoundation as GraphQLFoundationLogo,
37
- SvgGuild as GuildLogo,
38
- SvgHeltin as HeltinLogo,
39
- SvgHiveCombinationMark as HiveCombinationMark,
40
- InspectorLettermark,
41
- SvgKitql as KitQLLogo,
42
- SvgMesh as MeshLogo,
43
- SvgModules as ModulesLogo,
44
- SvgNextra as NextraLogo,
45
- SvgSse as SSELogo,
46
- ScalarsLettermark,
47
- SofaLettermark,
48
- SvgStitching as StitchingLogo,
49
- SvgTheGuild as TheGuild,
50
- SvgTools as ToolsLogo,
51
- SvgWs as WSLogo,
52
- SvgWhatsapp as WhatsAppLogo,
53
- SvgYoga as YogaLogo
54
- };
@@ -1,135 +0,0 @@
1
- // src/next.config.ts
2
- import path from "node:path";
3
- import withVideos from "next-videos";
4
- import nextra from "nextra";
5
- import remarkMdxDisableExplicitJsx from "remark-mdx-disable-explicit-jsx";
6
- import nextBundleAnalyzer from "@next/bundle-analyzer";
7
-
8
- // src/underscore-redirects.ts
9
- import { writeFile } from "node:fs/promises";
10
- import { join } from "node:path";
11
- var RunPromiseWebpackPlugin = class {
12
- constructor(asyncHook) {
13
- this.asyncHook = asyncHook;
14
- }
15
- apply(compiler) {
16
- compiler.hooks.beforeCompile.tapPromise("RunPromiseWebpackPlugin", this.asyncHook);
17
- }
18
- };
19
- var isWarningPrinted = false;
20
- function applyUnderscoreRedirects(config, meta) {
21
- config.plugins.push(
22
- new RunPromiseWebpackPlugin(async () => {
23
- const outDir = meta.dir;
24
- const outFile = join(outDir, "./public/_redirects");
25
- try {
26
- const redirects = meta.config.redirects ? Array.isArray(meta.config.redirects) ? meta.config.redirects : await meta.config.redirects() : [];
27
- if (redirects.length === 0) {
28
- if (!isWarningPrinted) {
29
- console.warn(
30
- '[@theguild/components] No redirects defined, no "_redirect" file is created!'
31
- );
32
- isWarningPrinted = true;
33
- }
34
- return;
35
- }
36
- const redirectsTxt = redirects.map((r) => `${r.source} ${r.destination} ${r.permanent ? 301 : 302}`).join("\n");
37
- await writeFile(outFile, redirectsTxt);
38
- } catch (error) {
39
- throw new Error(
40
- `Failed to generate "_redirects" file during build: ${error.message}`
41
- );
42
- }
43
- })
44
- );
45
- }
46
-
47
- // src/next.config.ts
48
- var defaultRemarkPlugins = [
49
- [
50
- // replace <iframe />, <video />, <source /> tags in MDX
51
- remarkMdxDisableExplicitJsx,
52
- { whiteList: ["iframe", "video", "source"] }
53
- ]
54
- ];
55
- var warnings = /* @__PURE__ */ new Set();
56
- var rehypeCheckFrontMatter = () => (_ast, file) => {
57
- const { description } = file.data.frontMatter;
58
- const filePath = path.relative(process.cwd(), file.history[0]);
59
- if (!filePath.includes("/pages/")) return;
60
- function warnOnce(message) {
61
- const msg = `[@theguild/components] SEO issue in "${filePath}": ${message}`;
62
- if (!warnings.has(msg)) {
63
- warnings.add(msg);
64
- console.warn(msg);
65
- }
66
- }
67
- if (!description) {
68
- warnOnce("The description is missing");
69
- } else if (description.length > 160) {
70
- warnOnce(
71
- `The description "${description}" is too long, should be less than 160 characters, not ${description.length}`
72
- );
73
- } else if (description.length < 50) {
74
- warnOnce(
75
- `The description "${description}" is too short, should be more than 50 characters, not ${description.length}`
76
- );
77
- }
78
- };
79
- function withGuildDocs({ nextraConfig, ...nextConfig } = {}) {
80
- if (nextConfig.webpack?.toString().includes("applyUnderscoreRedirects")) {
81
- throw new Error(
82
- "`applyUnderscoreRedirects` in `nextConfig.webpack` was already configured, remove it from your config"
83
- );
84
- }
85
- const withBundleAnalyzer = nextBundleAnalyzer({
86
- enabled: process.env.ANALYZE === "true"
87
- });
88
- const withNextra = nextra({
89
- theme: "nextra-theme-docs",
90
- defaultShowCopyCode: true,
91
- mdxOptions: {
92
- remarkPlugins: defaultRemarkPlugins,
93
- // Should be rehype since frontMatter is attached in remark plugins
94
- rehypePlugins: [rehypeCheckFrontMatter]
95
- },
96
- search: {
97
- codeblocks: true
98
- },
99
- ...nextraConfig,
100
- themeConfig: nextraConfig?.themeConfig || "./theme.config.tsx"
101
- });
102
- const siteUrl = process.env.SITE_URL || "";
103
- return withBundleAnalyzer(
104
- withVideos(
105
- withNextra({
106
- reactStrictMode: true,
107
- poweredByHeader: false,
108
- basePath: process.env.NEXT_BASE_PATH,
109
- ...nextConfig,
110
- env: {
111
- SITE_URL: siteUrl,
112
- ...nextConfig.env
113
- },
114
- webpack(config, meta) {
115
- applyUnderscoreRedirects(config, meta);
116
- return nextConfig.webpack?.(config, meta) || config;
117
- },
118
- experimental: {
119
- // TODO: Provoke white flash ⚪️💥 on initial loading with dark theme
120
- // optimizeCss: true,
121
- ...nextConfig.experimental
122
- },
123
- images: {
124
- unoptimized: true,
125
- // doesn't work with `next export`,
126
- ...nextConfig.images
127
- }
128
- })
129
- )
130
- );
131
- }
132
- export {
133
- defaultRemarkPlugins,
134
- withGuildDocs
135
- };