@brillout/docpress 0.4.4 → 0.4.6
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.ts +2 -1
- package/dist/index.js +22 -20
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -84,11 +84,12 @@ type Config = {
|
|
|
84
84
|
i18n?: true;
|
|
85
85
|
};
|
|
86
86
|
|
|
87
|
-
declare function Link(
|
|
87
|
+
declare function Link({ href, text, noBreadcrumb, doNotInferSectionTitle, titleNormalCase }: {
|
|
88
88
|
href: string;
|
|
89
89
|
text?: string | JSX.Element;
|
|
90
90
|
noBreadcrumb?: true;
|
|
91
91
|
doNotInferSectionTitle?: true;
|
|
92
|
+
titleNormalCase?: boolean;
|
|
92
93
|
}): JSX.Element;
|
|
93
94
|
|
|
94
95
|
declare function isRepoLink(href: string): boolean;
|
package/dist/index.js
CHANGED
|
@@ -27,34 +27,31 @@ import "./chunk-3QC7HYIF.js";
|
|
|
27
27
|
|
|
28
28
|
// src/components/Link.tsx
|
|
29
29
|
import React from "react";
|
|
30
|
-
function Link(
|
|
31
|
-
if (isRepoLink(props.href)) {
|
|
32
|
-
return /* @__PURE__ */ React.createElement(RepoLink, {
|
|
33
|
-
path: props.href,
|
|
34
|
-
text: props.text
|
|
35
|
-
});
|
|
36
|
-
} else {
|
|
37
|
-
return /* @__PURE__ */ React.createElement(DocLink, {
|
|
38
|
-
...props
|
|
39
|
-
});
|
|
40
|
-
}
|
|
41
|
-
}
|
|
42
|
-
function DocLink({
|
|
30
|
+
function Link({
|
|
43
31
|
href,
|
|
44
32
|
text,
|
|
45
33
|
noBreadcrumb,
|
|
46
|
-
doNotInferSectionTitle
|
|
34
|
+
doNotInferSectionTitle,
|
|
35
|
+
titleNormalCase
|
|
47
36
|
}) {
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
37
|
+
if (isRepoLink(href)) {
|
|
38
|
+
return /* @__PURE__ */ React.createElement(RepoLink, {
|
|
39
|
+
path: href,
|
|
40
|
+
text
|
|
41
|
+
});
|
|
42
|
+
} else {
|
|
43
|
+
const pageContext = usePageContext();
|
|
44
|
+
return /* @__PURE__ */ React.createElement("a", {
|
|
45
|
+
href
|
|
46
|
+
}, text || getTitle({ href, noBreadcrumb, pageContext, doNotInferSectionTitle, titleNormalCase }));
|
|
47
|
+
}
|
|
52
48
|
}
|
|
53
49
|
function getTitle({
|
|
54
50
|
href,
|
|
55
51
|
noBreadcrumb,
|
|
56
52
|
pageContext,
|
|
57
|
-
doNotInferSectionTitle
|
|
53
|
+
doNotInferSectionTitle,
|
|
54
|
+
titleNormalCase
|
|
58
55
|
}) {
|
|
59
56
|
let urlHash = null;
|
|
60
57
|
let hrefWithoutHash = href;
|
|
@@ -96,7 +93,9 @@ function getTitle({
|
|
|
96
93
|
!doNotInferSectionTitle,
|
|
97
94
|
`Page section title not found for <Link href="\`${href}\`" doNotInferSectionTitle={true} />.`
|
|
98
95
|
);
|
|
99
|
-
|
|
96
|
+
if (titleNormalCase === void 0)
|
|
97
|
+
titleNormalCase = pageContext.config.titleNormalCase;
|
|
98
|
+
sectionTitle = determineSectionTitle(href, titleNormalCase);
|
|
100
99
|
}
|
|
101
100
|
breadcrumbs.push(sectionTitle);
|
|
102
101
|
}
|
|
@@ -267,6 +266,9 @@ var inlang_default = "/assets/inlang-GFRWND6X.png";
|
|
|
267
266
|
|
|
268
267
|
// src/components/Sponsors/sponsorsList.ts
|
|
269
268
|
var individuals = [
|
|
269
|
+
{
|
|
270
|
+
username: "alexturpin"
|
|
271
|
+
},
|
|
270
272
|
{
|
|
271
273
|
username: "gu-stav"
|
|
272
274
|
},
|