@theguild/components 7.5.2 → 7.6.0

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/dist/index.d.mts CHANGED
@@ -5,8 +5,8 @@ export { createCatchAllMeta } from 'nextra/catch-all';
5
5
  export { Callout, Cards, Code, FileTree, Mermaid, RemoteContent, Steps, Table, Tabs, Td, Th, Tr } from 'nextra/components';
6
6
  export { useData, useMounted } from 'nextra/hooks';
7
7
  export { useMDXComponents } from 'nextra/mdx';
8
- import * as React$1 from 'react';
9
- import React__default, { ComponentProps, ReactNode, ReactElement, HTMLAttributes, ComponentPropsWithoutRef } from 'react';
8
+ import * as react from 'react';
9
+ import react__default, { ComponentProps, ReactNode, ReactElement, HTMLAttributes, ComponentPropsWithoutRef } from 'react';
10
10
  import * as url from 'url';
11
11
  import { ImageProps, StaticImageData } from 'next/image';
12
12
  import { LinkProps } from 'next/link';
@@ -141,7 +141,7 @@ interface IEditorProps {
141
141
  }
142
142
 
143
143
  type AnchorProps = ILink;
144
- declare const Anchor: React$1.ForwardRefExoticComponent<{
144
+ declare const Anchor: react.ForwardRefExoticComponent<{
145
145
  href: string | url.UrlObject;
146
146
  as?: string | url.UrlObject;
147
147
  replace?: boolean;
@@ -154,11 +154,11 @@ declare const Anchor: React$1.ForwardRefExoticComponent<{
154
154
  onMouseEnter?: React.MouseEventHandler<HTMLAnchorElement>;
155
155
  onTouchStart?: React.TouchEventHandler<HTMLAnchorElement>;
156
156
  onClick?: React.MouseEventHandler<HTMLAnchorElement>;
157
- } & Pick<React$1.DetailedHTMLProps<React$1.AnchorHTMLAttributes<HTMLAnchorElement>, HTMLAnchorElement>, "style" | "title" | "target" | "rel" | "className"> & {
158
- children: React$1.ReactNode;
157
+ } & Pick<react.DetailedHTMLProps<react.AnchorHTMLAttributes<HTMLAnchorElement>, HTMLAnchorElement>, "style" | "title" | "target" | "rel" | "className"> & {
158
+ children: react.ReactNode;
159
159
  newWindow?: boolean;
160
160
  sameSite?: boolean;
161
- } & React$1.RefAttributes<HTMLAnchorElement>>;
161
+ } & react.RefAttributes<HTMLAnchorElement>>;
162
162
 
163
163
  interface ButtonProps extends AnchorProps {
164
164
  variant?: 'primary' | 'secondary';
@@ -207,10 +207,27 @@ declare const MarketplaceList: ({ title, placeholder, items, pagination, classNa
207
207
 
208
208
  declare const MarketplaceSearch: ({ title, tagsFilter, placeholder, primaryList, secondaryList, queryList, className, colorScheme, }: IMarketplaceSearchProps) => ReactElement;
209
209
 
210
+ /**
211
+ * MDX components used both in Hive-rebranded websites,
212
+ * and older The Guild-themed websites.
213
+ */
210
214
  declare const mdxComponents: {
211
215
  [tag: string]: (props: object) => ReactElement;
212
216
  };
213
217
 
218
+ interface MDXLinkProps extends Omit<React.ComponentProps<typeof Anchor>, 'href' | 'children'> {
219
+ href?: string;
220
+ children?: React.ReactNode;
221
+ }
222
+ declare const MDXLink: react.ForwardRefExoticComponent<Omit<MDXLinkProps, "ref"> & react.RefAttributes<HTMLAnchorElement>>;
223
+
224
+ /**
225
+ * MDX components used only in Hive-rebranded websites.
226
+ */
227
+ declare const hiveMdxComponents: {
228
+ a: react.ForwardRefExoticComponent<Omit<MDXLinkProps, "ref"> & react.RefAttributes<HTMLAnchorElement>>;
229
+ };
230
+
214
231
  declare const NPMBadge: ({ name }: {
215
232
  name: string;
216
233
  }) => ReactElement;
@@ -255,7 +272,7 @@ interface HiveNavigationProps {
255
272
  developerMenu?: {
256
273
  href: string;
257
274
  title?: string;
258
- icon: React__default.FC<{
275
+ icon: react__default.FC<{
259
276
  className?: string;
260
277
  }>;
261
278
  children: ReactNode;
@@ -403,8 +420,9 @@ declare function DropdownItem({ children, onClick, className, href, ...props }:
403
420
  interface GuildDocsThemeConfig extends DocsThemeConfig {
404
421
  websiteName: string;
405
422
  description: string;
423
+ themeVersion?: 'hive-rebranding' | 'original';
406
424
  }
407
- declare function defineConfig({ websiteName, description, logo, ...config }: GuildDocsThemeConfig): DocsThemeConfig;
425
+ declare function defineConfig({ websiteName, description, logo, themeVersion, ...config }: GuildDocsThemeConfig): DocsThemeConfig;
408
426
 
409
427
  type Package = {
410
428
  readme: string;
@@ -426,4 +444,4 @@ declare module 'react' {
426
444
  }
427
445
  }
428
446
 
429
- export { Anchor, AncillaryProductCard, Button, CallToAction, CallToActionProps, CardsColorful, CookiesConsent, type CookiesConsentProps, DecorationIsolation, Dropdown, DropdownContent, DropdownItem, DropdownTrigger, ExploreMainProductCards, type ExploreMainProductCardsProps, FeatureList, Footer, GetYourAPIGameRightSection, GraphQLConfCard, type GraphQLConfCardProps, Heading, type HeadingProps, HeroGradient, HeroIllustration, HeroMarketplace, HeroVideo, HiveFooter, HiveNavigation, type HiveNavigationProps, type IEditorProps, type IFeatureListProps, type IFooterExtendedProps, type IHeroGradientProps, type IHeroIllustrationProps, type IHeroMarketplaceProps, type IHeroVideoProps, type IInfoListProps, type ILink, type IMarketplaceItemProps, type IMarketplaceItemsProps, type IMarketplaceListProps, type IMarketplaceSearchProps, type ISchemaPageProps, Image, InfoCard, type InfoCardProps, InfoList, LegacyPackageCmd, MainProductCard, MarketplaceList, MarketplaceSearch, NPMBadge, ProductCard, type ProductCardProps, Stud, type StudProps, TextLink, type TextLinkProps, ThemeSwitcherButton, ToolsAndLibrariesCards, VersionDropdown, type VersionDropdownProps, cn, defineConfig, fetchPackageInfo, getNavbarLogo, mdxComponents, productsItems };
447
+ export { Anchor, AncillaryProductCard, Button, CallToAction, CallToActionProps, CardsColorful, CookiesConsent, type CookiesConsentProps, DecorationIsolation, Dropdown, DropdownContent, DropdownItem, DropdownTrigger, ExploreMainProductCards, type ExploreMainProductCardsProps, FeatureList, Footer, GetYourAPIGameRightSection, GraphQLConfCard, type GraphQLConfCardProps, Heading, type HeadingProps, HeroGradient, HeroIllustration, HeroMarketplace, HeroVideo, HiveFooter, HiveNavigation, type HiveNavigationProps, type IEditorProps, type IFeatureListProps, type IFooterExtendedProps, type IHeroGradientProps, type IHeroIllustrationProps, type IHeroMarketplaceProps, type IHeroVideoProps, type IInfoListProps, type ILink, type IMarketplaceItemProps, type IMarketplaceItemsProps, type IMarketplaceListProps, type IMarketplaceSearchProps, type ISchemaPageProps, Image, InfoCard, type InfoCardProps, InfoList, LegacyPackageCmd, MDXLink, type MDXLinkProps, MainProductCard, MarketplaceList, MarketplaceSearch, NPMBadge, ProductCard, type ProductCardProps, Stud, type StudProps, TextLink, type TextLinkProps, ThemeSwitcherButton, ToolsAndLibrariesCards, VersionDropdown, type VersionDropdownProps, cn, defineConfig, fetchPackageInfo, getNavbarLogo, hiveMdxComponents, mdxComponents, productsItems };