@assistant-ui/react
Version:
React components for AI chat.
61 lines (60 loc) • 2.04 kB
JavaScript
var __defProp = Object.defineProperty;
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
var __getOwnPropNames = Object.getOwnPropertyNames;
var __hasOwnProp = Object.prototype.hasOwnProperty;
var __export = (target, all) => {
for (var name in all)
__defProp(target, name, { get: all[name], enumerable: true });
};
var __copyProps = (to, from, except, desc) => {
if (from && typeof from === "object" || typeof from === "function") {
for (let key of __getOwnPropNames(from))
if (!__hasOwnProp.call(to, key) && key !== except)
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
}
return to;
};
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
// src/api/ThreadListItemRuntime.ts
var ThreadListItemRuntime_exports = {};
__export(ThreadListItemRuntime_exports, {
ThreadListItemRuntimeImpl: () => ThreadListItemRuntimeImpl
});
module.exports = __toCommonJS(ThreadListItemRuntime_exports);
var ThreadListItemRuntimeImpl = class {
constructor(_core, _ThreadListBinding) {
this._core = _core;
this._ThreadListBinding = _ThreadListBinding;
}
get path() {
return this._core.path;
}
getState() {
return this._core.getState();
}
rename(newTitle) {
const state = this._core.getState();
return this._ThreadListBinding.rename(state.threadId, newTitle);
}
archive() {
const state = this._core.getState();
return this._ThreadListBinding.archive(state.threadId);
}
unarchive() {
const state = this._core.getState();
return this._ThreadListBinding.unarchive(state.threadId);
}
delete() {
const state = this._core.getState();
return this._ThreadListBinding.delete(state.threadId);
}
subscribe(callback) {
return this._core.subscribe(callback);
}
};
// Annotate the CommonJS export names for ESM import in node:
0 && (module.exports = {
ThreadListItemRuntimeImpl
});
//# sourceMappingURL=ThreadListItemRuntime.js.map
;