@assistant-ui/react-markdown 0.7.21 → 0.8.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.ts +0 -7
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +0 -6
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +0 -6
- package/dist/index.mjs.map +1 -1
- package/package.json +3 -18
- package/src/index.ts +0 -12
- package/dist/styles/markdown.css +0 -274
- package/dist/styles/markdown.css.map +0 -1
- package/dist/styles/tailwindcss/markdown.css +0 -106
- package/dist/styles/tailwindcss/markdown.css.json +0 -68
- package/dist/tailwindcss/index.d.ts +0 -9
- package/dist/tailwindcss/index.d.ts.map +0 -1
- package/dist/tailwindcss/index.js +0 -113
- package/dist/tailwindcss/index.js.map +0 -1
- package/dist/tailwindcss/index.mjs +0 -105
- package/dist/tailwindcss/index.mjs.map +0 -1
- package/dist/ui/code-header.d.ts +0 -4
- package/dist/ui/code-header.d.ts.map +0 -1
- package/dist/ui/code-header.js +0 -54
- package/dist/ui/code-header.js.map +0 -1
- package/dist/ui/code-header.mjs +0 -29
- package/dist/ui/code-header.mjs.map +0 -1
- package/dist/ui/markdown-text.d.ts +0 -4
- package/dist/ui/markdown-text.d.ts.map +0 -1
- package/dist/ui/markdown-text.js +0 -114
- package/dist/ui/markdown-text.js.map +0 -1
- package/dist/ui/markdown-text.mjs +0 -81
- package/dist/ui/markdown-text.mjs.map +0 -1
- package/dist/ui/useCopyToClipboard.d.ts +0 -11
- package/dist/ui/useCopyToClipboard.d.ts.map +0 -1
- package/dist/ui/useCopyToClipboard.js +0 -45
- package/dist/ui/useCopyToClipboard.js.map +0 -1
- package/dist/ui/useCopyToClipboard.mjs +0 -21
- package/dist/ui/useCopyToClipboard.mjs.map +0 -1
- package/src/styles/tailwindcss/markdown.css +0 -106
- package/src/tailwindcss/index.ts +0 -8
- package/src/ui/code-header.tsx +0 -32
- package/src/ui/markdown-text.tsx +0 -114
- package/src/ui/useCopyToClipboard.tsx +0 -26
- package/tailwindcss/README.md +0 -1
- package/tailwindcss/package-lock.json +0 -6
- package/tailwindcss/package.json +0 -5
|
@@ -1,113 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __create = Object.create;
|
|
3
|
-
var __defProp = Object.defineProperty;
|
|
4
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
-
var __getProtoOf = Object.getPrototypeOf;
|
|
7
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
-
var __commonJS = (cb, mod) => function __require() {
|
|
9
|
-
return mod || (0, cb[__getOwnPropNames(cb)[0]])((mod = { exports: {} }).exports, mod), mod.exports;
|
|
10
|
-
};
|
|
11
|
-
var __export = (target, all) => {
|
|
12
|
-
for (var name in all)
|
|
13
|
-
__defProp(target, name, { get: all[name], enumerable: true });
|
|
14
|
-
};
|
|
15
|
-
var __copyProps = (to, from, except, desc) => {
|
|
16
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
17
|
-
for (let key of __getOwnPropNames(from))
|
|
18
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
19
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
20
|
-
}
|
|
21
|
-
return to;
|
|
22
|
-
};
|
|
23
|
-
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
24
|
-
// If the importer is in node compatibility mode or this is not an ESM
|
|
25
|
-
// file that has been converted to a CommonJS file using a Babel-
|
|
26
|
-
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
27
|
-
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
28
|
-
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
29
|
-
mod
|
|
30
|
-
));
|
|
31
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
32
|
-
|
|
33
|
-
// ../../node_modules/.pnpm/tailwindcss@3.4.17/node_modules/tailwindcss/lib/util/createPlugin.js
|
|
34
|
-
var require_createPlugin = __commonJS({
|
|
35
|
-
"../../node_modules/.pnpm/tailwindcss@3.4.17/node_modules/tailwindcss/lib/util/createPlugin.js"(exports2) {
|
|
36
|
-
"use strict";
|
|
37
|
-
Object.defineProperty(exports2, "__esModule", {
|
|
38
|
-
value: true
|
|
39
|
-
});
|
|
40
|
-
Object.defineProperty(exports2, "default", {
|
|
41
|
-
enumerable: true,
|
|
42
|
-
get: function() {
|
|
43
|
-
return _default;
|
|
44
|
-
}
|
|
45
|
-
});
|
|
46
|
-
function createPlugin(plugin2, config) {
|
|
47
|
-
return {
|
|
48
|
-
handler: plugin2,
|
|
49
|
-
config
|
|
50
|
-
};
|
|
51
|
-
}
|
|
52
|
-
createPlugin.withOptions = function(pluginFunction, configFunction = () => ({})) {
|
|
53
|
-
const optionsFunction = function(options) {
|
|
54
|
-
return {
|
|
55
|
-
__options: options,
|
|
56
|
-
handler: pluginFunction(options),
|
|
57
|
-
config: configFunction(options)
|
|
58
|
-
};
|
|
59
|
-
};
|
|
60
|
-
optionsFunction.__isOptionsFunction = true;
|
|
61
|
-
optionsFunction.__pluginFunction = pluginFunction;
|
|
62
|
-
optionsFunction.__configFunction = configFunction;
|
|
63
|
-
return optionsFunction;
|
|
64
|
-
};
|
|
65
|
-
var _default = createPlugin;
|
|
66
|
-
}
|
|
67
|
-
});
|
|
68
|
-
|
|
69
|
-
// ../../node_modules/.pnpm/tailwindcss@3.4.17/node_modules/tailwindcss/lib/public/create-plugin.js
|
|
70
|
-
var require_create_plugin = __commonJS({
|
|
71
|
-
"../../node_modules/.pnpm/tailwindcss@3.4.17/node_modules/tailwindcss/lib/public/create-plugin.js"(exports2) {
|
|
72
|
-
"use strict";
|
|
73
|
-
Object.defineProperty(exports2, "__esModule", {
|
|
74
|
-
value: true
|
|
75
|
-
});
|
|
76
|
-
Object.defineProperty(exports2, "default", {
|
|
77
|
-
enumerable: true,
|
|
78
|
-
get: function() {
|
|
79
|
-
return _default;
|
|
80
|
-
}
|
|
81
|
-
});
|
|
82
|
-
var _createPlugin = /* @__PURE__ */ _interop_require_default(require_createPlugin());
|
|
83
|
-
function _interop_require_default(obj) {
|
|
84
|
-
return obj && obj.__esModule ? obj : {
|
|
85
|
-
default: obj
|
|
86
|
-
};
|
|
87
|
-
}
|
|
88
|
-
var _default = _createPlugin.default;
|
|
89
|
-
}
|
|
90
|
-
});
|
|
91
|
-
|
|
92
|
-
// ../../node_modules/.pnpm/tailwindcss@3.4.17/node_modules/tailwindcss/plugin.js
|
|
93
|
-
var require_plugin = __commonJS({
|
|
94
|
-
"../../node_modules/.pnpm/tailwindcss@3.4.17/node_modules/tailwindcss/plugin.js"(exports2, module2) {
|
|
95
|
-
"use strict";
|
|
96
|
-
var createPlugin = require_create_plugin();
|
|
97
|
-
module2.exports = (createPlugin.__esModule ? createPlugin : { default: createPlugin }).default;
|
|
98
|
-
}
|
|
99
|
-
});
|
|
100
|
-
|
|
101
|
-
// src/tailwindcss/index.ts
|
|
102
|
-
var tailwindcss_exports = {};
|
|
103
|
-
__export(tailwindcss_exports, {
|
|
104
|
-
default: () => tailwindcss_default
|
|
105
|
-
});
|
|
106
|
-
module.exports = __toCommonJS(tailwindcss_exports);
|
|
107
|
-
var import_plugin = __toESM(require_plugin());
|
|
108
|
-
var import_markdown_css = __toESM(require("../../dist/styles/tailwindcss/markdown.css.json"));
|
|
109
|
-
var auiPlugin = import_plugin.default.withOptions(() => ({ addComponents }) => {
|
|
110
|
-
addComponents(import_markdown_css.default);
|
|
111
|
-
});
|
|
112
|
-
var tailwindcss_default = auiPlugin;
|
|
113
|
-
//# sourceMappingURL=index.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../../node_modules/.pnpm/tailwindcss@3.4.17/node_modules/tailwindcss/lib/util/createPlugin.js","../../../../node_modules/.pnpm/tailwindcss@3.4.17/node_modules/tailwindcss/lib/public/create-plugin.js","../../../../node_modules/.pnpm/tailwindcss@3.4.17/node_modules/tailwindcss/plugin.js","../../src/tailwindcss/index.ts"],"sourcesContent":["\"use strict\";\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nObject.defineProperty(exports, \"default\", {\n enumerable: true,\n get: function() {\n return _default;\n }\n});\nfunction createPlugin(plugin, config) {\n return {\n handler: plugin,\n config\n };\n}\ncreatePlugin.withOptions = function(pluginFunction, configFunction = ()=>({})) {\n const optionsFunction = function(options) {\n return {\n __options: options,\n handler: pluginFunction(options),\n config: configFunction(options)\n };\n };\n optionsFunction.__isOptionsFunction = true;\n // Expose plugin dependencies so that `object-hash` returns a different\n // value if anything here changes, to ensure a rebuild is triggered.\n optionsFunction.__pluginFunction = pluginFunction;\n optionsFunction.__configFunction = configFunction;\n return optionsFunction;\n};\nconst _default = createPlugin;\n","\"use strict\";\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nObject.defineProperty(exports, \"default\", {\n enumerable: true,\n get: function() {\n return _default;\n }\n});\nconst _createPlugin = /*#__PURE__*/ _interop_require_default(require(\"../util/createPlugin\"));\nfunction _interop_require_default(obj) {\n return obj && obj.__esModule ? obj : {\n default: obj\n };\n}\nconst _default = _createPlugin.default;\n","let createPlugin = require('./lib/public/create-plugin')\nmodule.exports = (createPlugin.__esModule ? createPlugin : { default: createPlugin }).default\n","import plugin from \"tailwindcss/plugin.js\";\nimport markdownCSS from \"../../dist/styles/tailwindcss/markdown.css.json\";\n\nconst auiPlugin = plugin.withOptions<{}>(() => ({ addComponents }) => {\n addComponents(markdownCSS);\n});\n\nexport default auiPlugin;\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA,kGAAAA,UAAA;AAAA;AACA,WAAO,eAAeA,UAAS,cAAc;AAAA,MACzC,OAAO;AAAA,IACX,CA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AC3B,CAAC;AAED,IAAO,sBAAQ;","names":["exports","plugin","exports","exports","module","plugin","markdownCSS"]}
|
|
@@ -1,105 +0,0 @@
|
|
|
1
|
-
var __create = Object.create;
|
|
2
|
-
var __defProp = Object.defineProperty;
|
|
3
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
-
var __getProtoOf = Object.getPrototypeOf;
|
|
6
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
7
|
-
var __commonJS = (cb, mod) => function __require() {
|
|
8
|
-
return mod || (0, cb[__getOwnPropNames(cb)[0]])((mod = { exports: {} }).exports, mod), mod.exports;
|
|
9
|
-
};
|
|
10
|
-
var __copyProps = (to, from, except, desc) => {
|
|
11
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
-
for (let key of __getOwnPropNames(from))
|
|
13
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
15
|
-
}
|
|
16
|
-
return to;
|
|
17
|
-
};
|
|
18
|
-
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
19
|
-
// If the importer is in node compatibility mode or this is not an ESM
|
|
20
|
-
// file that has been converted to a CommonJS file using a Babel-
|
|
21
|
-
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
22
|
-
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
23
|
-
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
24
|
-
mod
|
|
25
|
-
));
|
|
26
|
-
|
|
27
|
-
// ../../node_modules/.pnpm/tailwindcss@3.4.17/node_modules/tailwindcss/lib/util/createPlugin.js
|
|
28
|
-
var require_createPlugin = __commonJS({
|
|
29
|
-
"../../node_modules/.pnpm/tailwindcss@3.4.17/node_modules/tailwindcss/lib/util/createPlugin.js"(exports) {
|
|
30
|
-
"use strict";
|
|
31
|
-
Object.defineProperty(exports, "__esModule", {
|
|
32
|
-
value: true
|
|
33
|
-
});
|
|
34
|
-
Object.defineProperty(exports, "default", {
|
|
35
|
-
enumerable: true,
|
|
36
|
-
get: function() {
|
|
37
|
-
return _default;
|
|
38
|
-
}
|
|
39
|
-
});
|
|
40
|
-
function createPlugin(plugin2, config) {
|
|
41
|
-
return {
|
|
42
|
-
handler: plugin2,
|
|
43
|
-
config
|
|
44
|
-
};
|
|
45
|
-
}
|
|
46
|
-
createPlugin.withOptions = function(pluginFunction, configFunction = () => ({})) {
|
|
47
|
-
const optionsFunction = function(options) {
|
|
48
|
-
return {
|
|
49
|
-
__options: options,
|
|
50
|
-
handler: pluginFunction(options),
|
|
51
|
-
config: configFunction(options)
|
|
52
|
-
};
|
|
53
|
-
};
|
|
54
|
-
optionsFunction.__isOptionsFunction = true;
|
|
55
|
-
optionsFunction.__pluginFunction = pluginFunction;
|
|
56
|
-
optionsFunction.__configFunction = configFunction;
|
|
57
|
-
return optionsFunction;
|
|
58
|
-
};
|
|
59
|
-
var _default = createPlugin;
|
|
60
|
-
}
|
|
61
|
-
});
|
|
62
|
-
|
|
63
|
-
// ../../node_modules/.pnpm/tailwindcss@3.4.17/node_modules/tailwindcss/lib/public/create-plugin.js
|
|
64
|
-
var require_create_plugin = __commonJS({
|
|
65
|
-
"../../node_modules/.pnpm/tailwindcss@3.4.17/node_modules/tailwindcss/lib/public/create-plugin.js"(exports) {
|
|
66
|
-
"use strict";
|
|
67
|
-
Object.defineProperty(exports, "__esModule", {
|
|
68
|
-
value: true
|
|
69
|
-
});
|
|
70
|
-
Object.defineProperty(exports, "default", {
|
|
71
|
-
enumerable: true,
|
|
72
|
-
get: function() {
|
|
73
|
-
return _default;
|
|
74
|
-
}
|
|
75
|
-
});
|
|
76
|
-
var _createPlugin = /* @__PURE__ */ _interop_require_default(require_createPlugin());
|
|
77
|
-
function _interop_require_default(obj) {
|
|
78
|
-
return obj && obj.__esModule ? obj : {
|
|
79
|
-
default: obj
|
|
80
|
-
};
|
|
81
|
-
}
|
|
82
|
-
var _default = _createPlugin.default;
|
|
83
|
-
}
|
|
84
|
-
});
|
|
85
|
-
|
|
86
|
-
// ../../node_modules/.pnpm/tailwindcss@3.4.17/node_modules/tailwindcss/plugin.js
|
|
87
|
-
var require_plugin = __commonJS({
|
|
88
|
-
"../../node_modules/.pnpm/tailwindcss@3.4.17/node_modules/tailwindcss/plugin.js"(exports, module) {
|
|
89
|
-
"use strict";
|
|
90
|
-
var createPlugin = require_create_plugin();
|
|
91
|
-
module.exports = (createPlugin.__esModule ? createPlugin : { default: createPlugin }).default;
|
|
92
|
-
}
|
|
93
|
-
});
|
|
94
|
-
|
|
95
|
-
// src/tailwindcss/index.ts
|
|
96
|
-
var import_plugin = __toESM(require_plugin());
|
|
97
|
-
import markdownCSS from "../../dist/styles/tailwindcss/markdown.css.json";
|
|
98
|
-
var auiPlugin = import_plugin.default.withOptions(() => ({ addComponents }) => {
|
|
99
|
-
addComponents(markdownCSS);
|
|
100
|
-
});
|
|
101
|
-
var tailwindcss_default = auiPlugin;
|
|
102
|
-
export {
|
|
103
|
-
tailwindcss_default as default
|
|
104
|
-
};
|
|
105
|
-
//# sourceMappingURL=index.mjs.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../../node_modules/.pnpm/tailwindcss@3.4.17/node_modules/tailwindcss/lib/util/createPlugin.js","../../../../node_modules/.pnpm/tailwindcss@3.4.17/node_modules/tailwindcss/lib/public/create-plugin.js","../../../../node_modules/.pnpm/tailwindcss@3.4.17/node_modules/tailwindcss/plugin.js","../../src/tailwindcss/index.ts"],"sourcesContent":["\"use strict\";\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nObject.defineProperty(exports, \"default\", {\n enumerable: true,\n get: function() {\n return _default;\n }\n});\nfunction createPlugin(plugin, config) {\n return {\n handler: plugin,\n config\n };\n}\ncreatePlugin.withOptions = function(pluginFunction, configFunction = ()=>({})) {\n const optionsFunction = function(options) {\n return {\n __options: options,\n handler: pluginFunction(options),\n config: configFunction(options)\n };\n };\n optionsFunction.__isOptionsFunction = true;\n // Expose plugin dependencies so that `object-hash` returns a different\n // value if anything here changes, to ensure a rebuild is triggered.\n optionsFunction.__pluginFunction = pluginFunction;\n optionsFunction.__configFunction = configFunction;\n return optionsFunction;\n};\nconst _default = createPlugin;\n","\"use strict\";\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nObject.defineProperty(exports, \"default\", {\n enumerable: true,\n get: function() {\n return _default;\n }\n});\nconst _createPlugin = /*#__PURE__*/ _interop_require_default(require(\"../util/createPlugin\"));\nfunction _interop_require_default(obj) {\n return obj && obj.__esModule ? obj : {\n default: obj\n };\n}\nconst _default = _createPlugin.default;\n","let createPlugin = require('./lib/public/create-plugin')\nmodule.exports = (createPlugin.__esModule ? createPlugin : { default: createPlugin }).default\n","import plugin from \"tailwindcss/plugin.js\";\nimport markdownCSS from \"../../dist/styles/tailwindcss/markdown.css.json\";\n\nconst auiPlugin = plugin.withOptions<{}>(() => ({ addComponents }) => {\n addComponents(markdownCSS);\n});\n\nexport default auiPlugin;\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AACA,WAAO,eAAe,SAAS,cAAc;AAAA,MACzC,OAAO;AAAA,IACX,CAAC;AACD,WAAO,eAAe,SAAS,WAAW;AAAA,MACtC,YAAY;AAAA,MACZ,KAAK,WAAW;AACZ,eAAO;AAAA,MACX;AAAA,IACJ,CAAC;AACD,aAAS,aAAaA,SAAQ,QAAQ;AAClC,aAAO;AAAA,QACH,SAASA;AAAA,QACT;AAAA,MACJ;AAAA,IACJ;AACA,iBAAa,cAAc,SAAS,gBAAgB,iBAAiB,OAAK,CAAC,IAAI;AAC3E,YAAM,kBAAkB,SAAS,SAAS;AACtC,eAAO;AAAA,UACH,WAAW;AAAA,UACX,SAAS,eAAe,OAAO;AAAA,UAC/B,QAAQ,eAAe,OAAO;AAAA,QAClC;AAAA,MACJ;AACA,sBAAgB,sBAAsB;AAGtC,sBAAgB,mBAAmB;AACnC,sBAAgB,mBAAmB;AACnC,aAAO;AAAA,IACX;AACA,QAAM,WAAW;AAAA;AAAA;;;AC/BjB;AAAA;AAAA;AACA,WAAO,eAAe,SAAS,cAAc;AAAA,MACzC,OAAO;AAAA,IACX,CAAC;AACD,WAAO,eAAe,SAAS,WAAW;AAAA,MACtC,YAAY;AAAA,MACZ,KAAK,WAAW;AACZ,eAAO;AAAA,MACX;AAAA,IACJ,CAAC;AACD,QAAM,gBAA8B,yCAAyB,sBAA+B;AAC5F,aAAS,yBAAyB,KAAK;AACnC,aAAO,OAAO,IAAI,aAAa,MAAM;AAAA,QACjC,SAAS;AAAA,MACb;AAAA,IACJ;AACA,QAAM,WAAW,cAAc;AAAA;AAAA;;;AChB/B;AAAA;AAAA;AAAA,QAAI,eAAe;AACnB,WAAO,WAAW,aAAa,aAAa,eAAe,EAAE,SAAS,aAAa,GAAG;AAAA;AAAA;;;ACDtF,oBAAmB;AACnB,OAAO,iBAAiB;AAExB,IAAM,YAAY,cAAAC,QAAO,YAAgB,MAAM,CAAC,EAAE,cAAc,MAAM;AACpE,gBAAc,WAAW;AAC3B,CAAC;AAED,IAAO,sBAAQ;","names":["plugin","plugin"]}
|
package/dist/ui/code-header.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"code-header.d.ts","sourceRoot":"","sources":["../../src/ui/code-header.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,EAAE,EAAE,MAAM,OAAO,CAAC;AAI3B,OAAO,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAC;AAKrD,eAAO,MAAM,UAAU,EAAE,EAAE,CAAC,eAAe,CAsB1C,CAAC"}
|
package/dist/ui/code-header.js
DELETED
|
@@ -1,54 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __defProp = Object.defineProperty;
|
|
3
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
-
var __export = (target, all) => {
|
|
7
|
-
for (var name in all)
|
|
8
|
-
__defProp(target, name, { get: all[name], enumerable: true });
|
|
9
|
-
};
|
|
10
|
-
var __copyProps = (to, from, except, desc) => {
|
|
11
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
-
for (let key of __getOwnPropNames(from))
|
|
13
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
15
|
-
}
|
|
16
|
-
return to;
|
|
17
|
-
};
|
|
18
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
|
-
|
|
20
|
-
// src/ui/code-header.tsx
|
|
21
|
-
var code_header_exports = {};
|
|
22
|
-
__export(code_header_exports, {
|
|
23
|
-
CodeHeader: () => CodeHeader
|
|
24
|
-
});
|
|
25
|
-
module.exports = __toCommonJS(code_header_exports);
|
|
26
|
-
var import_lucide_react = require("lucide-react");
|
|
27
|
-
var import_react = require("@assistant-ui/react");
|
|
28
|
-
var import_useCopyToClipboard = require("./useCopyToClipboard.js");
|
|
29
|
-
var import_jsx_runtime = require("react/jsx-runtime");
|
|
30
|
-
var { TooltipIconButton } = import_react.INTERNAL;
|
|
31
|
-
var CodeHeader = ({ language, code }) => {
|
|
32
|
-
const {
|
|
33
|
-
strings: {
|
|
34
|
-
code: { header: { copy: { tooltip = "Copy" } = {} } = {} } = {}
|
|
35
|
-
} = {}
|
|
36
|
-
} = (0, import_react.useThreadConfig)();
|
|
37
|
-
const { isCopied, copyToClipboard } = (0, import_useCopyToClipboard.useCopyToClipboard)();
|
|
38
|
-
const onCopy = () => {
|
|
39
|
-
if (!code || isCopied) return;
|
|
40
|
-
copyToClipboard(code);
|
|
41
|
-
};
|
|
42
|
-
return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", { className: "aui-code-header-root", children: [
|
|
43
|
-
/* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { className: "aui-code-header-language", children: language }),
|
|
44
|
-
/* @__PURE__ */ (0, import_jsx_runtime.jsxs)(TooltipIconButton, { tooltip, onClick: onCopy, children: [
|
|
45
|
-
!isCopied && /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_lucide_react.CopyIcon, {}),
|
|
46
|
-
isCopied && /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_lucide_react.CheckIcon, {})
|
|
47
|
-
] })
|
|
48
|
-
] });
|
|
49
|
-
};
|
|
50
|
-
// Annotate the CommonJS export names for ESM import in node:
|
|
51
|
-
0 && (module.exports = {
|
|
52
|
-
CodeHeader
|
|
53
|
-
});
|
|
54
|
-
//# sourceMappingURL=code-header.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/ui/code-header.tsx"],"sourcesContent":["import { FC } from \"react\";\nimport { CheckIcon, CopyIcon } from \"lucide-react\";\nimport { INTERNAL, useThreadConfig } from \"@assistant-ui/react\";\n\nimport { CodeHeaderProps } from \"../overrides/types\";\nimport { useCopyToClipboard } from \"./useCopyToClipboard\";\n\nconst { TooltipIconButton } = INTERNAL;\n\nexport const CodeHeader: FC<CodeHeaderProps> = ({ language, code }) => {\n const {\n strings: {\n code: { header: { copy: { tooltip = \"Copy\" } = {} } = {} } = {},\n } = {},\n } = useThreadConfig();\n\n const { isCopied, copyToClipboard } = useCopyToClipboard();\n const onCopy = () => {\n if (!code || isCopied) return;\n copyToClipboard(code);\n };\n\n return (\n <div className=\"aui-code-header-root\">\n <span className=\"aui-code-header-language\">{language}</span>\n <TooltipIconButton tooltip={tooltip} onClick={onCopy}>\n {!isCopied && <CopyIcon />}\n {isCopied && <CheckIcon />}\n </TooltipIconButton>\n </div>\n );\n};\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AACA,0BAAoC;AACpC,mBAA0C;AAG1C,gCAAmC;AAmB7B;AAjBN,IAAM,EAAE,kBAAkB,IAAI;AAEvB,IAAM,aAAkC,CAAC,EAAE,UAAU,KAAK,MAAM;AACrE,QAAM;AAAA,IACJ,SAAS;AAAA,MACP,MAAM,EAAE,QAAQ,EAAE,MAAM,EAAE,UAAU,OAAO,IAAI,CAAC,EAAE,IAAI,CAAC,EAAE,IAAI,CAAC;AAAA,IAChE,IAAI,CAAC;AAAA,EACP,QAAI,8BAAgB;AAEpB,QAAM,EAAE,UAAU,gBAAgB,QAAI,8CAAmB;AACzD,QAAM,SAAS,MAAM;AACnB,QAAI,CAAC,QAAQ,SAAU;AACvB,oBAAgB,IAAI;AAAA,EACtB;AAEA,SACE,6CAAC,SAAI,WAAU,wBACb;AAAA,gDAAC,UAAK,WAAU,4BAA4B,oBAAS;AAAA,IACrD,6CAAC,qBAAkB,SAAkB,SAAS,QAC3C;AAAA,OAAC,YAAY,4CAAC,gCAAS;AAAA,MACvB,YAAY,4CAAC,iCAAU;AAAA,OAC1B;AAAA,KACF;AAEJ;","names":[]}
|
package/dist/ui/code-header.mjs
DELETED
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
// src/ui/code-header.tsx
|
|
2
|
-
import { CheckIcon, CopyIcon } from "lucide-react";
|
|
3
|
-
import { INTERNAL, useThreadConfig } from "@assistant-ui/react";
|
|
4
|
-
import { useCopyToClipboard } from "./useCopyToClipboard.mjs";
|
|
5
|
-
import { jsx, jsxs } from "react/jsx-runtime";
|
|
6
|
-
var { TooltipIconButton } = INTERNAL;
|
|
7
|
-
var CodeHeader = ({ language, code }) => {
|
|
8
|
-
const {
|
|
9
|
-
strings: {
|
|
10
|
-
code: { header: { copy: { tooltip = "Copy" } = {} } = {} } = {}
|
|
11
|
-
} = {}
|
|
12
|
-
} = useThreadConfig();
|
|
13
|
-
const { isCopied, copyToClipboard } = useCopyToClipboard();
|
|
14
|
-
const onCopy = () => {
|
|
15
|
-
if (!code || isCopied) return;
|
|
16
|
-
copyToClipboard(code);
|
|
17
|
-
};
|
|
18
|
-
return /* @__PURE__ */ jsxs("div", { className: "aui-code-header-root", children: [
|
|
19
|
-
/* @__PURE__ */ jsx("span", { className: "aui-code-header-language", children: language }),
|
|
20
|
-
/* @__PURE__ */ jsxs(TooltipIconButton, { tooltip, onClick: onCopy, children: [
|
|
21
|
-
!isCopied && /* @__PURE__ */ jsx(CopyIcon, {}),
|
|
22
|
-
isCopied && /* @__PURE__ */ jsx(CheckIcon, {})
|
|
23
|
-
] })
|
|
24
|
-
] });
|
|
25
|
-
};
|
|
26
|
-
export {
|
|
27
|
-
CodeHeader
|
|
28
|
-
};
|
|
29
|
-
//# sourceMappingURL=code-header.mjs.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/ui/code-header.tsx"],"sourcesContent":["import { FC } from \"react\";\nimport { CheckIcon, CopyIcon } from \"lucide-react\";\nimport { INTERNAL, useThreadConfig } from \"@assistant-ui/react\";\n\nimport { CodeHeaderProps } from \"../overrides/types\";\nimport { useCopyToClipboard } from \"./useCopyToClipboard\";\n\nconst { TooltipIconButton } = INTERNAL;\n\nexport const CodeHeader: FC<CodeHeaderProps> = ({ language, code }) => {\n const {\n strings: {\n code: { header: { copy: { tooltip = \"Copy\" } = {} } = {} } = {},\n } = {},\n } = useThreadConfig();\n\n const { isCopied, copyToClipboard } = useCopyToClipboard();\n const onCopy = () => {\n if (!code || isCopied) return;\n copyToClipboard(code);\n };\n\n return (\n <div className=\"aui-code-header-root\">\n <span className=\"aui-code-header-language\">{language}</span>\n <TooltipIconButton tooltip={tooltip} onClick={onCopy}>\n {!isCopied && <CopyIcon />}\n {isCopied && <CheckIcon />}\n </TooltipIconButton>\n </div>\n );\n};\n"],"mappings":";AACA,SAAS,WAAW,gBAAgB;AACpC,SAAS,UAAU,uBAAuB;AAG1C,SAAS,0BAA0B;AAmB7B,cACA,YADA;AAjBN,IAAM,EAAE,kBAAkB,IAAI;AAEvB,IAAM,aAAkC,CAAC,EAAE,UAAU,KAAK,MAAM;AACrE,QAAM;AAAA,IACJ,SAAS;AAAA,MACP,MAAM,EAAE,QAAQ,EAAE,MAAM,EAAE,UAAU,OAAO,IAAI,CAAC,EAAE,IAAI,CAAC,EAAE,IAAI,CAAC;AAAA,IAChE,IAAI,CAAC;AAAA,EACP,IAAI,gBAAgB;AAEpB,QAAM,EAAE,UAAU,gBAAgB,IAAI,mBAAmB;AACzD,QAAM,SAAS,MAAM;AACnB,QAAI,CAAC,QAAQ,SAAU;AACvB,oBAAgB,IAAI;AAAA,EACtB;AAEA,SACE,qBAAC,SAAI,WAAU,wBACb;AAAA,wBAAC,UAAK,WAAU,4BAA4B,oBAAS;AAAA,IACrD,qBAAC,qBAAkB,SAAkB,SAAS,QAC3C;AAAA,OAAC,YAAY,oBAAC,YAAS;AAAA,MACvB,YAAY,oBAAC,aAAU;AAAA,OAC1B;AAAA,KACF;AAEJ;","names":[]}
|
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
import { MarkdownTextPrimitiveProps } from "../primitives/MarkdownText";
|
|
2
|
-
export type MakeMarkdownTextProps = MarkdownTextPrimitiveProps;
|
|
3
|
-
export declare const makeMarkdownText: ({ className, components: userComponents, ...rest }?: MakeMarkdownTextProps) => import("react").NamedExoticComponent<{}>;
|
|
4
|
-
//# sourceMappingURL=markdown-text.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"markdown-text.d.ts","sourceRoot":"","sources":["../../src/ui/markdown-text.tsx"],"names":[],"mappings":"AAGA,OAAO,EAEL,0BAA0B,EAC3B,MAAM,4BAA4B,CAAC;AAMpC,MAAM,MAAM,qBAAqB,GAAG,0BAA0B,CAAC;AAwE/D,eAAO,MAAM,gBAAgB,wDAI1B,qBAAqB,6CAyBvB,CAAC"}
|
package/dist/ui/markdown-text.js
DELETED
|
@@ -1,114 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __create = Object.create;
|
|
3
|
-
var __defProp = Object.defineProperty;
|
|
4
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
-
var __getProtoOf = Object.getPrototypeOf;
|
|
7
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
-
var __export = (target, all) => {
|
|
9
|
-
for (var name in all)
|
|
10
|
-
__defProp(target, name, { get: all[name], enumerable: true });
|
|
11
|
-
};
|
|
12
|
-
var __copyProps = (to, from, except, desc) => {
|
|
13
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
14
|
-
for (let key of __getOwnPropNames(from))
|
|
15
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
16
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
17
|
-
}
|
|
18
|
-
return to;
|
|
19
|
-
};
|
|
20
|
-
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
21
|
-
// If the importer is in node compatibility mode or this is not an ESM
|
|
22
|
-
// file that has been converted to a CommonJS file using a Babel-
|
|
23
|
-
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
24
|
-
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
25
|
-
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
26
|
-
mod
|
|
27
|
-
));
|
|
28
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
29
|
-
|
|
30
|
-
// src/ui/markdown-text.tsx
|
|
31
|
-
var markdown_text_exports = {};
|
|
32
|
-
__export(markdown_text_exports, {
|
|
33
|
-
makeMarkdownText: () => makeMarkdownText
|
|
34
|
-
});
|
|
35
|
-
module.exports = __toCommonJS(markdown_text_exports);
|
|
36
|
-
var import_react = require("react");
|
|
37
|
-
var import_code_header = require("./code-header.js");
|
|
38
|
-
var import_classnames = __toESM(require("classnames"));
|
|
39
|
-
var import_MarkdownText = require("../primitives/MarkdownText.js");
|
|
40
|
-
var import_react2 = require("@assistant-ui/react");
|
|
41
|
-
var import_PreOverride = require("../overrides/PreOverride.js");
|
|
42
|
-
var import_jsx_runtime = require("react/jsx-runtime");
|
|
43
|
-
var { withSmoothContextProvider, useSmoothStatus } = import_react2.INTERNAL;
|
|
44
|
-
var defaultComponents = {
|
|
45
|
-
h1: ({ node, className, ...props }) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)("h1", { className: (0, import_classnames.default)("aui-md-h1", className), ...props }),
|
|
46
|
-
h2: ({ node, className, ...props }) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)("h2", { className: (0, import_classnames.default)("aui-md-h2", className), ...props }),
|
|
47
|
-
h3: ({ node, className, ...props }) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)("h3", { className: (0, import_classnames.default)("aui-md-h3", className), ...props }),
|
|
48
|
-
h4: ({ node, className, ...props }) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)("h4", { className: (0, import_classnames.default)("aui-md-h4", className), ...props }),
|
|
49
|
-
h5: ({ node, className, ...props }) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)("h5", { className: (0, import_classnames.default)("aui-md-h5", className), ...props }),
|
|
50
|
-
h6: ({ node, className, ...props }) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)("h6", { className: (0, import_classnames.default)("aui-md-h6", className), ...props }),
|
|
51
|
-
p: ({ node, className, ...props }) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)("p", { className: (0, import_classnames.default)("aui-md-p", className), ...props }),
|
|
52
|
-
a: ({ node, className, ...props }) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)("a", { className: (0, import_classnames.default)("aui-md-a", className), ...props }),
|
|
53
|
-
blockquote: ({ node, className, ...props }) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
54
|
-
"blockquote",
|
|
55
|
-
{
|
|
56
|
-
className: (0, import_classnames.default)("aui-md-blockquote", className),
|
|
57
|
-
...props
|
|
58
|
-
}
|
|
59
|
-
),
|
|
60
|
-
ul: ({ node, className, ...props }) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)("ul", { className: (0, import_classnames.default)("aui-md-ul", className), ...props }),
|
|
61
|
-
ol: ({ node, className, ...props }) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)("ol", { className: (0, import_classnames.default)("aui-md-ol", className), ...props }),
|
|
62
|
-
hr: ({ node, className, ...props }) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)("hr", { className: (0, import_classnames.default)("aui-md-hr", className), ...props }),
|
|
63
|
-
table: ({ node, className, ...props }) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)("table", { className: (0, import_classnames.default)("aui-md-table", className), ...props }),
|
|
64
|
-
th: ({ node, className, ...props }) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)("th", { className: (0, import_classnames.default)("aui-md-th", className), ...props }),
|
|
65
|
-
td: ({ node, className, ...props }) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)("td", { className: (0, import_classnames.default)("aui-md-td", className), ...props }),
|
|
66
|
-
tr: ({ node, className, ...props }) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)("tr", { className: (0, import_classnames.default)("aui-md-tr", className), ...props }),
|
|
67
|
-
sup: ({ node, className, ...props }) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)("sup", { className: (0, import_classnames.default)("aui-md-sup", className), ...props }),
|
|
68
|
-
pre: ({ node, className, ...props }) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)("pre", { className: (0, import_classnames.default)("aui-md-pre", className), ...props }),
|
|
69
|
-
code: ({ node, className, ...props }) => {
|
|
70
|
-
const isCodeBlock = (0, import_PreOverride.useIsMarkdownCodeBlock)();
|
|
71
|
-
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
72
|
-
"code",
|
|
73
|
-
{
|
|
74
|
-
className: (0, import_classnames.default)(!isCodeBlock && "aui-md-inline-code", className),
|
|
75
|
-
...props
|
|
76
|
-
}
|
|
77
|
-
);
|
|
78
|
-
},
|
|
79
|
-
CodeHeader: import_code_header.CodeHeader
|
|
80
|
-
};
|
|
81
|
-
var makeMarkdownText = ({
|
|
82
|
-
className,
|
|
83
|
-
components: userComponents,
|
|
84
|
-
...rest
|
|
85
|
-
} = {}) => {
|
|
86
|
-
const components = {
|
|
87
|
-
...defaultComponents,
|
|
88
|
-
...Object.fromEntries(
|
|
89
|
-
// ignore undefined values, so undefined values do not override default components
|
|
90
|
-
Object.entries(userComponents ?? {}).filter(([_, v]) => v !== void 0)
|
|
91
|
-
)
|
|
92
|
-
};
|
|
93
|
-
const MarkdownTextImpl = () => {
|
|
94
|
-
const status = useSmoothStatus();
|
|
95
|
-
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
96
|
-
import_MarkdownText.MarkdownTextPrimitive,
|
|
97
|
-
{
|
|
98
|
-
components,
|
|
99
|
-
...rest,
|
|
100
|
-
className: (0, import_classnames.default)(
|
|
101
|
-
status.type === "running" && "aui-md-running",
|
|
102
|
-
className
|
|
103
|
-
)
|
|
104
|
-
}
|
|
105
|
-
);
|
|
106
|
-
};
|
|
107
|
-
MarkdownTextImpl.displayName = "MarkdownText";
|
|
108
|
-
return (0, import_react.memo)(withSmoothContextProvider(MarkdownTextImpl), () => true);
|
|
109
|
-
};
|
|
110
|
-
// Annotate the CommonJS export names for ESM import in node:
|
|
111
|
-
0 && (module.exports = {
|
|
112
|
-
makeMarkdownText
|
|
113
|
-
});
|
|
114
|
-
//# sourceMappingURL=markdown-text.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/ui/markdown-text.tsx"],"sourcesContent":["import { FC, memo } from \"react\";\nimport { CodeHeader } from \"./code-header\";\nimport classNames from \"classnames\";\nimport {\n MarkdownTextPrimitive,\n MarkdownTextPrimitiveProps,\n} from \"../primitives/MarkdownText\";\nimport { INTERNAL } from \"@assistant-ui/react\";\nimport { useIsMarkdownCodeBlock } from \"../overrides/PreOverride\";\n\nconst { withSmoothContextProvider, useSmoothStatus } = INTERNAL;\n\nexport type MakeMarkdownTextProps = MarkdownTextPrimitiveProps;\n\nconst defaultComponents: MakeMarkdownTextProps[\"components\"] = {\n h1: ({ node, className, ...props }) => (\n <h1 className={classNames(\"aui-md-h1\", className)} {...props} />\n ),\n h2: ({ node, className, ...props }) => (\n <h2 className={classNames(\"aui-md-h2\", className)} {...props} />\n ),\n h3: ({ node, className, ...props }) => (\n <h3 className={classNames(\"aui-md-h3\", className)} {...props} />\n ),\n h4: ({ node, className, ...props }) => (\n <h4 className={classNames(\"aui-md-h4\", className)} {...props} />\n ),\n h5: ({ node, className, ...props }) => (\n <h5 className={classNames(\"aui-md-h5\", className)} {...props} />\n ),\n h6: ({ node, className, ...props }) => (\n <h6 className={classNames(\"aui-md-h6\", className)} {...props} />\n ),\n p: ({ node, className, ...props }) => (\n <p className={classNames(\"aui-md-p\", className)} {...props} />\n ),\n a: ({ node, className, ...props }) => (\n <a className={classNames(\"aui-md-a\", className)} {...props} />\n ),\n blockquote: ({ node, className, ...props }) => (\n <blockquote\n className={classNames(\"aui-md-blockquote\", className)}\n {...props}\n />\n ),\n ul: ({ node, className, ...props }) => (\n <ul className={classNames(\"aui-md-ul\", className)} {...props} />\n ),\n ol: ({ node, className, ...props }) => (\n <ol className={classNames(\"aui-md-ol\", className)} {...props} />\n ),\n hr: ({ node, className, ...props }) => (\n <hr className={classNames(\"aui-md-hr\", className)} {...props} />\n ),\n table: ({ node, className, ...props }) => (\n <table className={classNames(\"aui-md-table\", className)} {...props} />\n ),\n th: ({ node, className, ...props }) => (\n <th className={classNames(\"aui-md-th\", className)} {...props} />\n ),\n td: ({ node, className, ...props }) => (\n <td className={classNames(\"aui-md-td\", className)} {...props} />\n ),\n tr: ({ node, className, ...props }) => (\n <tr className={classNames(\"aui-md-tr\", className)} {...props} />\n ),\n sup: ({ node, className, ...props }) => (\n <sup className={classNames(\"aui-md-sup\", className)} {...props} />\n ),\n pre: ({ node, className, ...props }) => (\n <pre className={classNames(\"aui-md-pre\", className)} {...props} />\n ),\n code: ({ node, className, ...props }) => {\n const isCodeBlock = useIsMarkdownCodeBlock();\n return (\n <code\n className={classNames(!isCodeBlock && \"aui-md-inline-code\", className)}\n {...props}\n />\n );\n },\n CodeHeader,\n};\n\nexport const makeMarkdownText = ({\n className,\n components: userComponents,\n ...rest\n}: MakeMarkdownTextProps = {}) => {\n const components = {\n ...defaultComponents,\n ...Object.fromEntries(\n // ignore undefined values, so undefined values do not override default components\n Object.entries(userComponents ?? {}).filter(([_, v]) => v !== undefined),\n ),\n };\n\n const MarkdownTextImpl: FC = () => {\n const status = useSmoothStatus();\n return (\n <MarkdownTextPrimitive\n components={components}\n {...rest}\n className={classNames(\n status.type === \"running\" && \"aui-md-running\",\n className,\n )}\n />\n );\n };\n MarkdownTextImpl.displayName = \"MarkdownText\";\n\n return memo(withSmoothContextProvider(MarkdownTextImpl), () => true);\n};\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,mBAAyB;AACzB,yBAA2B;AAC3B,wBAAuB;AACvB,0BAGO;AACP,IAAAA,gBAAyB;AACzB,yBAAuC;AAQnC;AANJ,IAAM,EAAE,2BAA2B,gBAAgB,IAAI;AAIvD,IAAM,oBAAyD;AAAA,EAC7D,IAAI,CAAC,EAAE,MAAM,WAAW,GAAG,MAAM,MAC/B,4CAAC,QAAG,eAAW,kBAAAC,SAAW,aAAa,SAAS,GAAI,GAAG,OAAO;AAAA,EAEhE,IAAI,CAAC,EAAE,MAAM,WAAW,GAAG,MAAM,MAC/B,4CAAC,QAAG,eAAW,kBAAAA,SAAW,aAAa,SAAS,GAA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AAA;AAAA,MAER,OAAO,QAAQ,kBAAkB,CAAC,CAAC,EAAE,OAAO,CAAC,CAAC,GAAG,CAAC,MAAM,MAAM,MAAS;AAAA,IACzE;AAAA,EACF;AAEA,QAAM,mBAAuB,MAAM;AACjC,UAAM,SAAS,gBAAgB;AAC/B,WACE;AAAA,MAAC;AAAA;AAAA,QACC;AAAA,QACC,GAAG;AAAA,QACJ,eAAW,kBAAAA;AAAA,UACT,OAAO,SAAS,aAAa;AAAA,UAC7B;AAAA,QACF;AAAA;AAAA,IACF;AAAA,EAEJ;AACA,mBAAiB,cAAc;AAE/B,aAAO,mBAAK,0BAA0B,gBAAgB,GAAG,MAAM,IAAI;AACrE;","names":["import_react","classNames"]}
|
|
@@ -1,81 +0,0 @@
|
|
|
1
|
-
// src/ui/markdown-text.tsx
|
|
2
|
-
import { memo } from "react";
|
|
3
|
-
import { CodeHeader } from "./code-header.mjs";
|
|
4
|
-
import classNames from "classnames";
|
|
5
|
-
import {
|
|
6
|
-
MarkdownTextPrimitive
|
|
7
|
-
} from "../primitives/MarkdownText.mjs";
|
|
8
|
-
import { INTERNAL } from "@assistant-ui/react";
|
|
9
|
-
import { useIsMarkdownCodeBlock } from "../overrides/PreOverride.mjs";
|
|
10
|
-
import { jsx } from "react/jsx-runtime";
|
|
11
|
-
var { withSmoothContextProvider, useSmoothStatus } = INTERNAL;
|
|
12
|
-
var defaultComponents = {
|
|
13
|
-
h1: ({ node, className, ...props }) => /* @__PURE__ */ jsx("h1", { className: classNames("aui-md-h1", className), ...props }),
|
|
14
|
-
h2: ({ node, className, ...props }) => /* @__PURE__ */ jsx("h2", { className: classNames("aui-md-h2", className), ...props }),
|
|
15
|
-
h3: ({ node, className, ...props }) => /* @__PURE__ */ jsx("h3", { className: classNames("aui-md-h3", className), ...props }),
|
|
16
|
-
h4: ({ node, className, ...props }) => /* @__PURE__ */ jsx("h4", { className: classNames("aui-md-h4", className), ...props }),
|
|
17
|
-
h5: ({ node, className, ...props }) => /* @__PURE__ */ jsx("h5", { className: classNames("aui-md-h5", className), ...props }),
|
|
18
|
-
h6: ({ node, className, ...props }) => /* @__PURE__ */ jsx("h6", { className: classNames("aui-md-h6", className), ...props }),
|
|
19
|
-
p: ({ node, className, ...props }) => /* @__PURE__ */ jsx("p", { className: classNames("aui-md-p", className), ...props }),
|
|
20
|
-
a: ({ node, className, ...props }) => /* @__PURE__ */ jsx("a", { className: classNames("aui-md-a", className), ...props }),
|
|
21
|
-
blockquote: ({ node, className, ...props }) => /* @__PURE__ */ jsx(
|
|
22
|
-
"blockquote",
|
|
23
|
-
{
|
|
24
|
-
className: classNames("aui-md-blockquote", className),
|
|
25
|
-
...props
|
|
26
|
-
}
|
|
27
|
-
),
|
|
28
|
-
ul: ({ node, className, ...props }) => /* @__PURE__ */ jsx("ul", { className: classNames("aui-md-ul", className), ...props }),
|
|
29
|
-
ol: ({ node, className, ...props }) => /* @__PURE__ */ jsx("ol", { className: classNames("aui-md-ol", className), ...props }),
|
|
30
|
-
hr: ({ node, className, ...props }) => /* @__PURE__ */ jsx("hr", { className: classNames("aui-md-hr", className), ...props }),
|
|
31
|
-
table: ({ node, className, ...props }) => /* @__PURE__ */ jsx("table", { className: classNames("aui-md-table", className), ...props }),
|
|
32
|
-
th: ({ node, className, ...props }) => /* @__PURE__ */ jsx("th", { className: classNames("aui-md-th", className), ...props }),
|
|
33
|
-
td: ({ node, className, ...props }) => /* @__PURE__ */ jsx("td", { className: classNames("aui-md-td", className), ...props }),
|
|
34
|
-
tr: ({ node, className, ...props }) => /* @__PURE__ */ jsx("tr", { className: classNames("aui-md-tr", className), ...props }),
|
|
35
|
-
sup: ({ node, className, ...props }) => /* @__PURE__ */ jsx("sup", { className: classNames("aui-md-sup", className), ...props }),
|
|
36
|
-
pre: ({ node, className, ...props }) => /* @__PURE__ */ jsx("pre", { className: classNames("aui-md-pre", className), ...props }),
|
|
37
|
-
code: ({ node, className, ...props }) => {
|
|
38
|
-
const isCodeBlock = useIsMarkdownCodeBlock();
|
|
39
|
-
return /* @__PURE__ */ jsx(
|
|
40
|
-
"code",
|
|
41
|
-
{
|
|
42
|
-
className: classNames(!isCodeBlock && "aui-md-inline-code", className),
|
|
43
|
-
...props
|
|
44
|
-
}
|
|
45
|
-
);
|
|
46
|
-
},
|
|
47
|
-
CodeHeader
|
|
48
|
-
};
|
|
49
|
-
var makeMarkdownText = ({
|
|
50
|
-
className,
|
|
51
|
-
components: userComponents,
|
|
52
|
-
...rest
|
|
53
|
-
} = {}) => {
|
|
54
|
-
const components = {
|
|
55
|
-
...defaultComponents,
|
|
56
|
-
...Object.fromEntries(
|
|
57
|
-
// ignore undefined values, so undefined values do not override default components
|
|
58
|
-
Object.entries(userComponents ?? {}).filter(([_, v]) => v !== void 0)
|
|
59
|
-
)
|
|
60
|
-
};
|
|
61
|
-
const MarkdownTextImpl = () => {
|
|
62
|
-
const status = useSmoothStatus();
|
|
63
|
-
return /* @__PURE__ */ jsx(
|
|
64
|
-
MarkdownTextPrimitive,
|
|
65
|
-
{
|
|
66
|
-
components,
|
|
67
|
-
...rest,
|
|
68
|
-
className: classNames(
|
|
69
|
-
status.type === "running" && "aui-md-running",
|
|
70
|
-
className
|
|
71
|
-
)
|
|
72
|
-
}
|
|
73
|
-
);
|
|
74
|
-
};
|
|
75
|
-
MarkdownTextImpl.displayName = "MarkdownText";
|
|
76
|
-
return memo(withSmoothContextProvider(MarkdownTextImpl), () => true);
|
|
77
|
-
};
|
|
78
|
-
export {
|
|
79
|
-
makeMarkdownText
|
|
80
|
-
};
|
|
81
|
-
//# sourceMappingURL=markdown-text.mjs.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/ui/markdown-text.tsx"],"sourcesContent":["import { FC, memo } from \"react\";\nimport { CodeHeader } from \"./code-header\";\nimport classNames from \"classnames\";\nimport {\n MarkdownTextPrimitive,\n MarkdownTextPrimitiveProps,\n} from \"../primitives/MarkdownText\";\nimport { INTERNAL } from \"@assistant-ui/react\";\nimport { useIsMarkdownCodeBlock } from \"../overrides/PreOverride\";\n\nconst { withSmoothContextProvider, useSmoothStatus } = INTERNAL;\n\nexport type MakeMarkdownTextProps = MarkdownTextPrimitiveProps;\n\nconst defaultComponents: MakeMarkdownTextProps[\"components\"] = {\n h1: ({ node, className, ...props }) => (\n <h1 className={classNames(\"aui-md-h1\", className)} {...props} />\n ),\n h2: ({ node, className, ...props }) => (\n <h2 className={classNames(\"aui-md-h2\", className)} {...props} />\n ),\n h3: ({ node, className, ...props }) => (\n <h3 className={classNames(\"aui-md-h3\", className)} {...props} />\n ),\n h4: ({ node, className, ...props }) => (\n <h4 className={classNames(\"aui-md-h4\", className)} {...props} />\n ),\n h5: ({ node, className, ...props }) => (\n <h5 className={classNames(\"aui-md-h5\", className)} {...props} />\n ),\n h6: ({ node, className, ...props }) => (\n <h6 className={classNames(\"aui-md-h6\", className)} {...props} />\n ),\n p: ({ node, className, ...props }) => (\n <p className={classNames(\"aui-md-p\", className)} {...props} />\n ),\n a: ({ node, className, ...props }) => (\n <a className={classNames(\"aui-md-a\", className)} {...props} />\n ),\n blockquote: ({ node, className, ...props }) => (\n <blockquote\n className={classNames(\"aui-md-blockquote\", className)}\n {...props}\n />\n ),\n ul: ({ node, className, ...props }) => (\n <ul className={classNames(\"aui-md-ul\", className)} {...props} />\n ),\n ol: ({ node, className, ...props }) => (\n <ol className={classNames(\"aui-md-ol\", className)} {...props} />\n ),\n hr: ({ node, className, ...props }) => (\n <hr className={classNames(\"aui-md-hr\", className)} {...props} />\n ),\n table: ({ node, className, ...props }) => (\n <table className={classNames(\"aui-md-table\", className)} {...props} />\n ),\n th: ({ node, className, ...props }) => (\n <th className={classNames(\"aui-md-th\", className)} {...props} />\n ),\n td: ({ node, className, ...props }) => (\n <td className={classNames(\"aui-md-td\", className)} {...props} />\n ),\n tr: ({ node, className, ...props }) => (\n <tr className={classNames(\"aui-md-tr\", className)} {...props} />\n ),\n sup: ({ node, className, ...props }) => (\n <sup className={classNames(\"aui-md-sup\", className)} {...props} />\n ),\n pre: ({ node, className, ...props }) => (\n <pre className={classNames(\"aui-md-pre\", className)} {...props} />\n ),\n code: ({ node, className, ...props }) => {\n const isCodeBlock = useIsMarkdownCodeBlock();\n return (\n <code\n className={classNames(!isCodeBlock && \"aui-md-inline-code\", className)}\n {...props}\n />\n );\n },\n CodeHeader,\n};\n\nexport const makeMarkdownText = ({\n className,\n components: userComponents,\n ...rest\n}: MakeMarkdownTextProps = {}) => {\n const components = {\n ...defaultComponents,\n ...Object.fromEntries(\n // ignore undefined values, so undefined values do not override default components\n Object.entries(userComponents ?? {}).filter(([_, v]) => v !== undefined),\n ),\n };\n\n const MarkdownTextImpl: FC = () => {\n const status = useSmoothStatus();\n return (\n <MarkdownTextPrimitive\n components={components}\n {...rest}\n className={classNames(\n status.type === \"running\" && \"aui-md-running\",\n className,\n )}\n />\n );\n };\n MarkdownTextImpl.displayName = \"MarkdownText\";\n\n return memo(withSmoothContextProvider(MarkdownTextImpl), () => true);\n};\n"],"mappings":";AAAA,SAAa,YAAY;AACzB,SAAS,kBAAkB;AAC3B,OAAO,gBAAgB;AACvB;AAAA,EACE;AAAA,OAEK;AACP,SAAS,gBAAgB;AACzB,SAAS,8BAA8B;AAQnC;AANJ,IAAM,EAAE,2BAA2B,gBAAgB,IAAI;AAIvD,IAAM,oBAAyD;AAAA,EAC7D,IAAI,CAAC,EAAE,MAAM,WAAW,GAAG,MAAM,MAC/B,oBAAC,QAAG,WAAW,WAAW,aAAa,SAAS,GAAI,GAAG,OAAO;AAAA,EAEhE,IAAI,CAAC,EAAE,MAAM,WAAW,GAAG,MAAM,MAC/B,oBAAC,QAAG,WAAW,WAAW,aAAa,SAAS,GAAI,GAAG,OAAO;AAAA,EAEhE,IAAI,CAAC,EAAE,MAAM,WAAW,GAAG,MAAM,MAC/B,oBAAC,QAAG,WAAW,WAAW,aAAa,SAAS,GAAI,GAAG,OAAO;AAAA,EAEhE,IAAI,CAAC,EAAE,MAAM,WAAW,GAAG,MAAM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EAEJ;AACA,mBAAiB,cAAc;AAE/B,SAAO,KAAK,0BAA0B,gBAAgB,GAAG,MAAM,IAAI;AACrE;","names":[]}
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
declare namespace useCopyToClipboard {
|
|
2
|
-
interface Options {
|
|
3
|
-
copiedDuration?: number;
|
|
4
|
-
}
|
|
5
|
-
}
|
|
6
|
-
export declare const useCopyToClipboard: ({ copiedDuration, }?: useCopyToClipboard.Options) => {
|
|
7
|
-
isCopied: boolean;
|
|
8
|
-
copyToClipboard: (value: string) => void;
|
|
9
|
-
};
|
|
10
|
-
export {};
|
|
11
|
-
//# sourceMappingURL=useCopyToClipboard.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"useCopyToClipboard.d.ts","sourceRoot":"","sources":["../../src/ui/useCopyToClipboard.tsx"],"names":[],"mappings":"AAIA,kBAAU,kBAAkB,CAAC;IAC3B,UAAiB,OAAO;QACtB,cAAc,CAAC,EAAE,MAAM,CAAC;KACzB;CACF;AAED,eAAO,MAAM,kBAAkB,yBAE5B,kBAAkB,CAAC,OAAO;;6BAGK,MAAM;CAUvC,CAAC"}
|