hyperbook 0.88.2 → 0.89.2
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/assets/shell.css
CHANGED
|
@@ -295,6 +295,13 @@ a.jump.previous::before {
|
|
|
295
295
|
font-weight: bold;
|
|
296
296
|
}
|
|
297
297
|
|
|
298
|
+
.sidebar>.author>.author-version,
|
|
299
|
+
.nav-drawer-content>.author>.author-version {
|
|
300
|
+
display: block;
|
|
301
|
+
font-size: 0.7rem;
|
|
302
|
+
opacity: 0.6;
|
|
303
|
+
}
|
|
304
|
+
|
|
298
305
|
.mobile-nav {
|
|
299
306
|
display: none;
|
|
300
307
|
margin-left: 1rem;
|
package/dist/index.js
CHANGED
|
@@ -55625,6 +55625,7 @@ function makeBaseCtx(root, hyperbookJson, basePath, rootProject) {
|
|
|
55625
55625
|
return {
|
|
55626
55626
|
root,
|
|
55627
55627
|
config: hyperbookJson,
|
|
55628
|
+
version: package_json_1.default.version,
|
|
55628
55629
|
makeUrl: (p, base, page, options = { versioned: true }) => {
|
|
55629
55630
|
if (typeof p === "string") {
|
|
55630
55631
|
if (p.includes("://") || p.startsWith("data:")) {
|
|
@@ -177376,9 +177377,13 @@ var remarkDirectiveSqlIde_default = (ctx) => () => {
|
|
|
177376
177377
|
if (node3.name !== name) return;
|
|
177377
177378
|
const data = node3.data || (node3.data = {});
|
|
177378
177379
|
const attributes4 = node3.attributes || {};
|
|
177379
|
-
|
|
177380
|
+
let {
|
|
177380
177381
|
id = hash(node3),
|
|
177381
|
-
db
|
|
177382
|
+
db,
|
|
177383
|
+
height = ctx.config.elements?.sqlide?.height || "600px"
|
|
177384
|
+
} = attributes4;
|
|
177385
|
+
if (!db) {
|
|
177386
|
+
db = ctx.config.elements?.sqlide?.db ? ctx.makeUrl(ctx.config.elements?.sqlide?.db, "public") : ctx.makeUrl(
|
|
177382
177387
|
[
|
|
177383
177388
|
"directive-sqlide",
|
|
177384
177389
|
"include",
|
|
@@ -177389,9 +177394,10 @@ var remarkDirectiveSqlIde_default = (ctx) => () => {
|
|
|
177389
177394
|
"assets",
|
|
177390
177395
|
void 0,
|
|
177391
177396
|
{ versioned: false }
|
|
177392
|
-
)
|
|
177393
|
-
|
|
177394
|
-
|
|
177397
|
+
);
|
|
177398
|
+
} else {
|
|
177399
|
+
db = ctx.makeUrl(db, "public", ctx.navigation.current || void 0);
|
|
177400
|
+
}
|
|
177395
177401
|
expectContainerDirective(node3, file, name);
|
|
177396
177402
|
registerDirective(
|
|
177397
177403
|
file,
|
|
@@ -178758,6 +178764,24 @@ ${ctx.config.cloud ? `HYPERBOOK_CLOUD = ${JSON.stringify(ctx.config.cloud).repla
|
|
|
178758
178764
|
}
|
|
178759
178765
|
]
|
|
178760
178766
|
},
|
|
178767
|
+
...(ctx.config.version ?? "console") === "console" && ctx.version ? [
|
|
178768
|
+
{
|
|
178769
|
+
type: "element",
|
|
178770
|
+
tagName: "script",
|
|
178771
|
+
properties: {},
|
|
178772
|
+
children: [
|
|
178773
|
+
{
|
|
178774
|
+
type: "raw",
|
|
178775
|
+
value: `
|
|
178776
|
+
console.log(
|
|
178777
|
+
"%c" +
|
|
178778
|
+
"Hyperbook v${ctx.version}",
|
|
178779
|
+
"font-family: monospace; font-size: 16px;"
|
|
178780
|
+
);`
|
|
178781
|
+
}
|
|
178782
|
+
]
|
|
178783
|
+
}
|
|
178784
|
+
] : [],
|
|
178761
178785
|
{
|
|
178762
178786
|
type: "element",
|
|
178763
178787
|
tagName: "script",
|
|
@@ -178940,6 +178964,52 @@ var resolveEmoji = (text9) => {
|
|
|
178940
178964
|
return github_emojis_default[name] ?? `:${name}:`;
|
|
178941
178965
|
});
|
|
178942
178966
|
};
|
|
178967
|
+
var makeAuthorElement = (ctx) => {
|
|
178968
|
+
const versionMode = ctx.config.version ?? "console";
|
|
178969
|
+
const showTextVersion = versionMode === "text" && ctx.version;
|
|
178970
|
+
const showTooltip = versionMode === "tooltip" && ctx.version;
|
|
178971
|
+
return {
|
|
178972
|
+
type: "element",
|
|
178973
|
+
tagName: "a",
|
|
178974
|
+
properties: {
|
|
178975
|
+
class: "author",
|
|
178976
|
+
href: "https://hyperbook.openpatch.org",
|
|
178977
|
+
...showTooltip ? { title: `Hyperbook v${ctx.version}` } : {}
|
|
178978
|
+
},
|
|
178979
|
+
children: [
|
|
178980
|
+
{
|
|
178981
|
+
type: "text",
|
|
178982
|
+
value: "Powered by "
|
|
178983
|
+
},
|
|
178984
|
+
{
|
|
178985
|
+
type: "element",
|
|
178986
|
+
tagName: "b",
|
|
178987
|
+
properties: {},
|
|
178988
|
+
children: [
|
|
178989
|
+
{
|
|
178990
|
+
type: "text",
|
|
178991
|
+
value: "Hyperbook"
|
|
178992
|
+
}
|
|
178993
|
+
]
|
|
178994
|
+
},
|
|
178995
|
+
...showTextVersion ? [
|
|
178996
|
+
{
|
|
178997
|
+
type: "element",
|
|
178998
|
+
tagName: "span",
|
|
178999
|
+
properties: {
|
|
179000
|
+
class: "author-version"
|
|
179001
|
+
},
|
|
179002
|
+
children: [
|
|
179003
|
+
{
|
|
179004
|
+
type: "text",
|
|
179005
|
+
value: ctx.version
|
|
179006
|
+
}
|
|
179007
|
+
]
|
|
179008
|
+
}
|
|
179009
|
+
] : []
|
|
179010
|
+
]
|
|
179011
|
+
};
|
|
179012
|
+
};
|
|
178943
179013
|
var buildBreadcrumbPath = (ctx) => {
|
|
178944
179014
|
const currentHref = ctx.navigation.current?.href;
|
|
178945
179015
|
if (!currentHref) return [];
|
|
@@ -179540,31 +179610,7 @@ var makeHeaderElements = (ctx) => {
|
|
|
179540
179610
|
},
|
|
179541
179611
|
children: [
|
|
179542
179612
|
...makeNavigationElements(ctx),
|
|
179543
|
-
|
|
179544
|
-
type: "element",
|
|
179545
|
-
tagName: "a",
|
|
179546
|
-
properties: {
|
|
179547
|
-
class: "author",
|
|
179548
|
-
href: "https://hyperbook.openpatch.org"
|
|
179549
|
-
},
|
|
179550
|
-
children: [
|
|
179551
|
-
{
|
|
179552
|
-
type: "text",
|
|
179553
|
-
value: "Powered by "
|
|
179554
|
-
},
|
|
179555
|
-
{
|
|
179556
|
-
type: "element",
|
|
179557
|
-
tagName: "b",
|
|
179558
|
-
properties: {},
|
|
179559
|
-
children: [
|
|
179560
|
-
{
|
|
179561
|
-
type: "text",
|
|
179562
|
-
value: "Hyperbook"
|
|
179563
|
-
}
|
|
179564
|
-
]
|
|
179565
|
-
}
|
|
179566
|
-
]
|
|
179567
|
-
}
|
|
179613
|
+
makeAuthorElement(ctx)
|
|
179568
179614
|
]
|
|
179569
179615
|
}
|
|
179570
179616
|
]
|
|
@@ -180125,31 +180171,7 @@ var makeJump = (ctx) => {
|
|
|
180125
180171
|
var makeSidebar = (ctx) => {
|
|
180126
180172
|
const elements = [
|
|
180127
180173
|
...makeNavigationElements(ctx),
|
|
180128
|
-
|
|
180129
|
-
type: "element",
|
|
180130
|
-
tagName: "a",
|
|
180131
|
-
properties: {
|
|
180132
|
-
class: "author",
|
|
180133
|
-
href: "https://hyperbook.openpatch.org"
|
|
180134
|
-
},
|
|
180135
|
-
children: [
|
|
180136
|
-
{
|
|
180137
|
-
type: "text",
|
|
180138
|
-
value: "Powered by "
|
|
180139
|
-
},
|
|
180140
|
-
{
|
|
180141
|
-
type: "element",
|
|
180142
|
-
tagName: "b",
|
|
180143
|
-
properties: {},
|
|
180144
|
-
children: [
|
|
180145
|
-
{
|
|
180146
|
-
type: "text",
|
|
180147
|
-
value: "Hyperbook"
|
|
180148
|
-
}
|
|
180149
|
-
]
|
|
180150
|
-
}
|
|
180151
|
-
]
|
|
180152
|
-
}
|
|
180174
|
+
makeAuthorElement(ctx)
|
|
180153
180175
|
];
|
|
180154
180176
|
return [
|
|
180155
180177
|
{
|
|
@@ -201531,7 +201553,7 @@ module.exports = /*#__PURE__*/JSON.parse('{"application/1d-interleaved-parityfec
|
|
|
201531
201553
|
/***/ ((module) => {
|
|
201532
201554
|
|
|
201533
201555
|
"use strict";
|
|
201534
|
-
module.exports = /*#__PURE__*/JSON.parse('{"name":"hyperbook","version":"0.
|
|
201556
|
+
module.exports = /*#__PURE__*/JSON.parse('{"name":"hyperbook","version":"0.89.2","author":"Mike Barkmin","homepage":"https://github.com/openpatch/hyperbook#readme","license":"MIT","bin":{"hyperbook":"./dist/index.js"},"files":["dist"],"publishConfig":{"access":"public"},"repository":{"type":"git","url":"git+https://github.com/openpatch/hyperbook.git","directory":"packages/hyperbook"},"bugs":{"url":"https://github.com/openpatch/hyperbook/issues"},"engines":{"node":">=18"},"scripts":{"version":"pnpm build","lint":"tsc --noEmit","dev":"ncc build ./index.ts -w -o dist/","build":"rimraf dist && ncc build ./index.ts -o ./dist/ --no-cache --no-source-map-register --external favicons --external sharp && node postbuild.mjs"},"dependencies":{"favicons":"^7.2.0"},"devDependencies":{"create-hyperbook":"workspace:*","@hyperbook/fs":"workspace:*","@hyperbook/markdown":"workspace:*","@hyperbook/types":"workspace:*","@pnpm/exportable-manifest":"1000.0.6","@types/archiver":"6.0.3","@types/async-retry":"1.4.9","@types/cross-spawn":"6.0.6","@types/lunr":"^2.3.7","@types/prompts":"2.4.9","@types/tar":"6.1.13","@types/ws":"^8.5.14","@vercel/ncc":"0.38.3","archiver":"7.0.1","async-retry":"1.3.3","chalk":"5.4.1","chokidar":"4.0.3","commander":"12.1.0","cpy":"11.1.0","cross-spawn":"7.0.6","domutils":"^3.2.2","extract-zip":"^2.0.1","got":"12.6.0","htmlparser2":"^10.0.0","lunr":"^2.3.9","lunr-languages":"^1.14.0","mime":"^4.0.6","prompts":"2.4.2","rimraf":"6.0.1","tar":"7.4.3","update-check":"1.5.4","ws":"^8.18.0"}}');
|
|
201535
201557
|
|
|
201536
201558
|
/***/ })
|
|
201537
201559
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "hyperbook",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.89.2",
|
|
4
4
|
"author": "Mike Barkmin",
|
|
5
5
|
"homepage": "https://github.com/openpatch/hyperbook#readme",
|
|
6
6
|
"license": "MIT",
|
|
@@ -56,10 +56,10 @@
|
|
|
56
56
|
"tar": "7.4.3",
|
|
57
57
|
"update-check": "1.5.4",
|
|
58
58
|
"ws": "^8.18.0",
|
|
59
|
-
"create-hyperbook": "0.3.
|
|
60
|
-
"@hyperbook/
|
|
61
|
-
"@hyperbook/
|
|
62
|
-
"@hyperbook/
|
|
59
|
+
"create-hyperbook": "0.3.6",
|
|
60
|
+
"@hyperbook/markdown": "0.60.2",
|
|
61
|
+
"@hyperbook/types": "0.23.0",
|
|
62
|
+
"@hyperbook/fs": "0.25.0"
|
|
63
63
|
},
|
|
64
64
|
"scripts": {
|
|
65
65
|
"version": "pnpm build",
|