@inkeep/cxkit-docusaurus 0.5.3 → 0.5.5
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/define-config.cjs +1 -1
- package/dist/define-config.d.cts +6 -1
- package/dist/define-config.d.ts +6 -1
- package/dist/define-config.js +4 -2
- package/dist/theme/ChatButton.cjs +1 -0
- package/dist/theme/ChatButton.js +10 -0
- package/dist/theme/Root.cjs +1 -0
- package/dist/theme/Root.js +8 -0
- package/dist/theme/SearchBar.cjs +1 -0
- package/dist/theme/SearchBar.js +10 -0
- package/dist/utils/config.cjs +1 -0
- package/dist/utils/config.js +29 -0
- package/package.json +3 -4
package/dist/define-config.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=e=>e;exports.defineConfig=n;
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=e=>{typeof window<"u"&&(window.InkeepConfig=e)};exports.defineConfig=n;
|
package/dist/define-config.d.cts
CHANGED
|
@@ -1,3 +1,8 @@
|
|
|
1
1
|
import { PluginConfig } from './types';
|
|
2
2
|
export type * from '@inkeep/cxkit-react';
|
|
3
|
-
export declare const defineConfig: (config: PluginConfig) =>
|
|
3
|
+
export declare const defineConfig: (config: PluginConfig) => void;
|
|
4
|
+
declare global {
|
|
5
|
+
interface Window {
|
|
6
|
+
InkeepConfig: PluginConfig;
|
|
7
|
+
}
|
|
8
|
+
}
|
package/dist/define-config.d.ts
CHANGED
|
@@ -1,3 +1,8 @@
|
|
|
1
1
|
import { PluginConfig } from './types';
|
|
2
2
|
export type * from '@inkeep/cxkit-react';
|
|
3
|
-
export declare const defineConfig: (config: PluginConfig) =>
|
|
3
|
+
export declare const defineConfig: (config: PluginConfig) => void;
|
|
4
|
+
declare global {
|
|
5
|
+
interface Window {
|
|
6
|
+
InkeepConfig: PluginConfig;
|
|
7
|
+
}
|
|
8
|
+
}
|
package/dist/define-config.js
CHANGED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const u=require("react"),c=require("@inkeep/cxkit-react"),a=require("../utils/config.cjs");function i(e){const n=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const t in e)if(t!=="default"){const o=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(n,t,o.get?o:{enumerable:!0,get:()=>e[t]})}}return n.default=e,Object.freeze(n)}const r=i(u);function l(){const e=a.useConfig("ChatButton");return e?r.createElement(r.Fragment,null,r.createElement(c.InkeepChatButton,{...e})):null}exports.default=l;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import * as t from "react";
|
|
2
|
+
import { InkeepChatButton as n } from "@inkeep/cxkit-react";
|
|
3
|
+
import { useConfig as r } from "../utils/config.js";
|
|
4
|
+
function u() {
|
|
5
|
+
const e = r("ChatButton");
|
|
6
|
+
return e ? /* @__PURE__ */ t.createElement(t.Fragment, null, /* @__PURE__ */ t.createElement(n, { ...e })) : null;
|
|
7
|
+
}
|
|
8
|
+
export {
|
|
9
|
+
u as default
|
|
10
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("react"),u=require("./ChatButton.cjs");function r({children:t}){return e.createElement(e.Fragment,null,t,e.createElement(u.default,null))}exports.default=r;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const a=require("react"),o=require("@inkeep/cxkit-react"),u=require("../utils/config.cjs");function i(e){const r=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const t in e)if(t!=="default"){const c=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(r,t,c.get?c:{enumerable:!0,get:()=>e[t]})}}return r.default=e,Object.freeze(r)}const n=i(a);function l(){const e=u.useConfig("SearchBar");return e?n.createElement(n.Fragment,null,n.createElement(o.InkeepSearchBar,{...e})):null}exports.default=l;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import * as r from "react";
|
|
2
|
+
import { InkeepSearchBar as t } from "@inkeep/cxkit-react";
|
|
3
|
+
import { useConfig as a } from "../utils/config.js";
|
|
4
|
+
function c() {
|
|
5
|
+
const e = a("SearchBar");
|
|
6
|
+
return e ? /* @__PURE__ */ r.createElement(r.Fragment, null, /* @__PURE__ */ r.createElement(t, { ...e })) : null;
|
|
7
|
+
}
|
|
8
|
+
export {
|
|
9
|
+
c as default
|
|
10
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const c=require("@docusaurus/useDocusaurusContext"),i=require("merge-anything");function d(r){const{siteConfig:t}=c(),e=t.themeConfig,s=typeof window<"u"?window.InkeepConfig:{},n=i.merge(e.inkeep??{},s??{})[r];if(!n)return null;const o=e.prism.theme,g=e.prism.darkTheme||o,m={baseSettings:{primaryBrandColor:"",colorMode:{sync:{target:"html",attributes:["data-theme"],isDarkMode:a=>a["data-theme"]==="dark"}},organizationDisplayName:t.title,theme:{syntaxHighlighter:{lightTheme:o,darkTheme:g}}}};return i.merge(m,n??{})}exports.useConfig=d;
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import h from "@docusaurus/useDocusaurusContext";
|
|
2
|
+
import { merge as i } from "merge-anything";
|
|
3
|
+
function p(r) {
|
|
4
|
+
const { siteConfig: t } = h(), e = t.themeConfig, s = typeof window < "u" ? window.InkeepConfig : {}, o = i(e.inkeep ?? {}, s ?? {})[r];
|
|
5
|
+
if (!o) return null;
|
|
6
|
+
const n = e.prism.theme, m = e.prism.darkTheme || n, a = {
|
|
7
|
+
baseSettings: {
|
|
8
|
+
primaryBrandColor: "",
|
|
9
|
+
colorMode: {
|
|
10
|
+
sync: {
|
|
11
|
+
target: "html",
|
|
12
|
+
attributes: ["data-theme"],
|
|
13
|
+
isDarkMode: (g) => g["data-theme"] === "dark"
|
|
14
|
+
}
|
|
15
|
+
},
|
|
16
|
+
organizationDisplayName: t.title,
|
|
17
|
+
theme: {
|
|
18
|
+
syntaxHighlighter: {
|
|
19
|
+
lightTheme: n,
|
|
20
|
+
darkTheme: m
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
};
|
|
25
|
+
return i(a, o ?? {});
|
|
26
|
+
}
|
|
27
|
+
export {
|
|
28
|
+
p as useConfig
|
|
29
|
+
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@inkeep/cxkit-docusaurus",
|
|
3
|
-
"version": "0.5.
|
|
3
|
+
"version": "0.5.5",
|
|
4
4
|
"description": "Docusaurus plugin for Inkeep Chat and Search components",
|
|
5
5
|
"license": "Inkeep, Inc. Customer License (IICL) v1.1",
|
|
6
6
|
"homepage": "",
|
|
@@ -35,12 +35,12 @@
|
|
|
35
35
|
"typescript": "5.7.3",
|
|
36
36
|
"vite": "5.4.11",
|
|
37
37
|
"vite-plugin-dts": "4.4.0",
|
|
38
|
-
"@inkeep/cxkit-types": "0.5.
|
|
38
|
+
"@inkeep/cxkit-types": "0.5.5"
|
|
39
39
|
},
|
|
40
40
|
"dependencies": {
|
|
41
41
|
"merge-anything": "6.0.2",
|
|
42
42
|
"path": "^0.12.7",
|
|
43
|
-
"@inkeep/cxkit-react": "0.5.
|
|
43
|
+
"@inkeep/cxkit-react": "0.5.5"
|
|
44
44
|
},
|
|
45
45
|
"module": "dist/index.js",
|
|
46
46
|
"types": "dist/index.d.ts",
|
|
@@ -60,7 +60,6 @@
|
|
|
60
60
|
},
|
|
61
61
|
"scripts": {
|
|
62
62
|
"build": "vite build",
|
|
63
|
-
"lint": "biome lint ./src",
|
|
64
63
|
"typecheck": "tsc"
|
|
65
64
|
}
|
|
66
65
|
}
|