mito-ai 0.1.37__py3-none-any.whl → 0.1.38__py3-none-any.whl
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.
Potentially problematic release.
This version of mito-ai might be problematic. Click here for more details.
- mito_ai/__init__.py +9 -1
- mito_ai/_version.py +1 -1
- mito_ai/app_builder/handlers.py +30 -30
- mito_ai/app_builder/models.py +1 -1
- mito_ai/log/handlers.py +10 -3
- mito_ai/log/urls.py +3 -3
- mito_ai/streamlit_conversion/streamlit_agent_handler.py +22 -6
- mito_ai/streamlit_conversion/streamlit_system_prompt.py +11 -0
- mito_ai/streamlit_conversion/streamlit_utils.py +8 -6
- mito_ai/streamlit_conversion/validate_and_run_streamlit_code.py +1 -0
- mito_ai/streamlit_preview/__init__.py +7 -0
- mito_ai/streamlit_preview/handlers.py +161 -0
- mito_ai/streamlit_preview/manager.py +159 -0
- mito_ai/streamlit_preview/urls.py +22 -0
- mito_ai/tests/streamlit_conversion/test_streamlit_agent_handler.py +16 -15
- mito_ai/tests/streamlit_conversion/test_streamlit_utils.py +4 -5
- mito_ai/tests/streamlit_preview/test_streamlit_preview_manager.py +302 -0
- mito_ai/utils/telemetry_utils.py +28 -1
- {mito_ai-0.1.37.data → mito_ai-0.1.38.data}/data/share/jupyter/labextensions/mito_ai/build_log.json +1 -1
- {mito_ai-0.1.37.data → mito_ai-0.1.38.data}/data/share/jupyter/labextensions/mito_ai/package.json +2 -2
- {mito_ai-0.1.37.data → mito_ai-0.1.38.data}/data/share/jupyter/labextensions/mito_ai/schemas/mito_ai/package.json.orig +1 -1
- {mito_ai-0.1.37.data → mito_ai-0.1.38.data}/data/share/jupyter/labextensions/mito_ai/schemas/mito_ai/toolbar-buttons.json +6 -1
- mito_ai-0.1.37.data/data/share/jupyter/labextensions/mito_ai/static/lib_index_js.831f63b48760c7119b9b.js → mito_ai-0.1.38.data/data/share/jupyter/labextensions/mito_ai/static/lib_index_js.5d1d7c234e2dc7c9d97b.js +542 -56
- mito_ai-0.1.38.data/data/share/jupyter/labextensions/mito_ai/static/lib_index_js.5d1d7c234e2dc7c9d97b.js.map +1 -0
- mito_ai-0.1.37.data/data/share/jupyter/labextensions/mito_ai/static/remoteEntry.93ecc9bc0edba61535cc.js → mito_ai-0.1.38.data/data/share/jupyter/labextensions/mito_ai/static/remoteEntry.bcce4ea34631acf6dbbe.js +5 -5
- mito_ai-0.1.37.data/data/share/jupyter/labextensions/mito_ai/static/remoteEntry.93ecc9bc0edba61535cc.js.map → mito_ai-0.1.38.data/data/share/jupyter/labextensions/mito_ai/static/remoteEntry.bcce4ea34631acf6dbbe.js.map +1 -1
- {mito_ai-0.1.37.dist-info → mito_ai-0.1.38.dist-info}/METADATA +1 -1
- {mito_ai-0.1.37.dist-info → mito_ai-0.1.38.dist-info}/RECORD +39 -34
- mito_ai-0.1.37.data/data/share/jupyter/labextensions/mito_ai/static/lib_index_js.831f63b48760c7119b9b.js.map +0 -1
- {mito_ai-0.1.37.data → mito_ai-0.1.38.data}/data/etc/jupyter/jupyter_server_config.d/mito_ai.json +0 -0
- {mito_ai-0.1.37.data → mito_ai-0.1.38.data}/data/share/jupyter/labextensions/mito_ai/static/style.js +0 -0
- {mito_ai-0.1.37.data → mito_ai-0.1.38.data}/data/share/jupyter/labextensions/mito_ai/static/style_index_js.5876024bb17dbd6a3ee6.js +0 -0
- {mito_ai-0.1.37.data → mito_ai-0.1.38.data}/data/share/jupyter/labextensions/mito_ai/static/style_index_js.5876024bb17dbd6a3ee6.js.map +0 -0
- {mito_ai-0.1.37.data → mito_ai-0.1.38.data}/data/share/jupyter/labextensions/mito_ai/static/vendors-node_modules_semver_index_js.9795f79265ddb416864b.js +0 -0
- {mito_ai-0.1.37.data → mito_ai-0.1.38.data}/data/share/jupyter/labextensions/mito_ai/static/vendors-node_modules_semver_index_js.9795f79265ddb416864b.js.map +0 -0
- {mito_ai-0.1.37.data → mito_ai-0.1.38.data}/data/share/jupyter/labextensions/mito_ai/static/vendors-node_modules_vscode-diff_dist_index_js.ea55f1f9346638aafbcf.js +0 -0
- {mito_ai-0.1.37.data → mito_ai-0.1.38.data}/data/share/jupyter/labextensions/mito_ai/static/vendors-node_modules_vscode-diff_dist_index_js.ea55f1f9346638aafbcf.js.map +0 -0
- {mito_ai-0.1.37.dist-info → mito_ai-0.1.38.dist-info}/WHEEL +0 -0
- {mito_ai-0.1.37.dist-info → mito_ai-0.1.38.dist-info}/entry_points.txt +0 -0
- {mito_ai-0.1.37.dist-info → mito_ai-0.1.38.dist-info}/licenses/LICENSE +0 -0
|
@@ -235,6 +235,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
235
235
|
*/
|
|
236
236
|
class ChatHistoryManager {
|
|
237
237
|
constructor(contextManager, notebookTracker, initialHistory) {
|
|
238
|
+
this._allAssumptions = new Set();
|
|
238
239
|
this.getLastAIMessageIndex = () => {
|
|
239
240
|
// We assume that assistant messages are always separated by user messages.
|
|
240
241
|
// This allows us to simply find the last assistant message in the history.
|
|
@@ -262,9 +263,37 @@ class ChatHistoryManager {
|
|
|
262
263
|
this.contextManager = contextManager;
|
|
263
264
|
// Save the notebook tracker
|
|
264
265
|
this.notebookTracker = notebookTracker;
|
|
266
|
+
// Initialize assumptions from existing history
|
|
267
|
+
this.initializeAssumptionsFromHistory();
|
|
268
|
+
}
|
|
269
|
+
initializeAssumptionsFromHistory() {
|
|
270
|
+
this._allAssumptions.clear();
|
|
271
|
+
this.displayOptimizedChatHistory.forEach(item => {
|
|
272
|
+
var _a;
|
|
273
|
+
if ((_a = item.agentResponse) === null || _a === void 0 ? void 0 : _a.analysis_assumptions) {
|
|
274
|
+
item.agentResponse.analysis_assumptions.forEach(assumption => {
|
|
275
|
+
this._allAssumptions.add(assumption);
|
|
276
|
+
});
|
|
277
|
+
}
|
|
278
|
+
});
|
|
279
|
+
}
|
|
280
|
+
deduplicateAssumptions(agentResponse) {
|
|
281
|
+
var _a;
|
|
282
|
+
if (!((_a = agentResponse.analysis_assumptions) === null || _a === void 0 ? void 0 : _a.length)) {
|
|
283
|
+
return agentResponse;
|
|
284
|
+
}
|
|
285
|
+
const newAssumptions = agentResponse.analysis_assumptions.filter(assumption => !this._allAssumptions.has(assumption));
|
|
286
|
+
newAssumptions.forEach(assumption => this._allAssumptions.add(assumption));
|
|
287
|
+
return {
|
|
288
|
+
...agentResponse,
|
|
289
|
+
analysis_assumptions: newAssumptions.length > 0 ? newAssumptions : undefined
|
|
290
|
+
};
|
|
265
291
|
}
|
|
266
292
|
createDuplicateChatHistoryManager() {
|
|
267
|
-
|
|
293
|
+
const duplicateManager = new ChatHistoryManager(this.contextManager, this.notebookTracker, this.displayOptimizedChatHistory);
|
|
294
|
+
// Copy the assumptions set to the duplicate
|
|
295
|
+
duplicateManager._allAssumptions = new Set(this._allAssumptions);
|
|
296
|
+
return duplicateManager;
|
|
268
297
|
}
|
|
269
298
|
getDisplayOptimizedHistory() {
|
|
270
299
|
return this.displayOptimizedChatHistory;
|
|
@@ -456,7 +485,7 @@ class ChatHistoryManager {
|
|
|
456
485
|
message: aiMessage,
|
|
457
486
|
type: 'openai message',
|
|
458
487
|
promptType: 'agent:execution',
|
|
459
|
-
agentResponse: agentResponse
|
|
488
|
+
agentResponse: this.deduplicateAssumptions(agentResponse)
|
|
460
489
|
});
|
|
461
490
|
}
|
|
462
491
|
}
|
|
@@ -899,7 +928,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
899
928
|
|
|
900
929
|
|
|
901
930
|
|
|
902
|
-
const ChatInput = ({ app, initialContent, placeholder, onSave, onCancel, isEditing, contextManager, notebookTracker, renderMimeRegistry, displayActiveCellCode = true, agentModeEnabled = false, }) => {
|
|
931
|
+
const ChatInput = ({ app, initialContent, placeholder, onSave, onCancel, isEditing, contextManager, notebookTracker, renderMimeRegistry, displayActiveCellCode = true, agentModeEnabled = false, agentExecutionStatus = 'idle', }) => {
|
|
903
932
|
var _a;
|
|
904
933
|
const [input, setInput] = (0,react__WEBPACK_IMPORTED_MODULE_0__.useState)(initialContent);
|
|
905
934
|
const [expandedVariables, setExpandedVariables] = (0,react__WEBPACK_IMPORTED_MODULE_0__.useState)([]);
|
|
@@ -1052,6 +1081,17 @@ const ChatInput = ({ app, initialContent, placeholder, onSave, onCancel, isEditi
|
|
|
1052
1081
|
setDropdownFilter('');
|
|
1053
1082
|
setIsDropdownFromButton(false);
|
|
1054
1083
|
};
|
|
1084
|
+
const mapAdditionalContext = () => {
|
|
1085
|
+
return additionalContext.map(context => {
|
|
1086
|
+
if (context.type === 'db') {
|
|
1087
|
+
return {
|
|
1088
|
+
type: context.type,
|
|
1089
|
+
value: context.value
|
|
1090
|
+
};
|
|
1091
|
+
}
|
|
1092
|
+
return context;
|
|
1093
|
+
});
|
|
1094
|
+
};
|
|
1055
1095
|
// Update the expandedVariables arr when the variable manager changes
|
|
1056
1096
|
(0,react__WEBPACK_IMPORTED_MODULE_0__.useEffect)(() => {
|
|
1057
1097
|
const expandedVariables = [
|
|
@@ -1101,7 +1141,7 @@ const ChatInput = ({ app, initialContent, placeholder, onSave, onCancel, isEditi
|
|
|
1101
1141
|
} }, "\uFF20 Add Context"),
|
|
1102
1142
|
additionalContext.map((context, index) => (react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_components_SelectedContextContainer__WEBPACK_IMPORTED_MODULE_8__["default"], { key: `${context.type}-${context.value}-${index}`, title: context.type === 'db' && context.display ? context.display : context.value, type: context.type, onRemove: () => setAdditionalContext(additionalContext.filter((_, i) => i !== index)) })))),
|
|
1103
1143
|
react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", { className: 'chat-input-text-area-container' },
|
|
1104
|
-
react__WEBPACK_IMPORTED_MODULE_0___default().createElement("textarea", { ref: textAreaRef, className: (0,_utils_classNames__WEBPACK_IMPORTED_MODULE_5__.classNames)("message", "message-user", 'chat-input', { "agent-mode": agentModeEnabled }), placeholder: placeholder, value: input, onChange: handleInputChange, onKeyDown: (e) => {
|
|
1144
|
+
react__WEBPACK_IMPORTED_MODULE_0___default().createElement("textarea", { ref: textAreaRef, className: (0,_utils_classNames__WEBPACK_IMPORTED_MODULE_5__.classNames)("message", "message-user", 'chat-input', { "agent-mode": agentModeEnabled }), placeholder: placeholder, value: input, disabled: agentExecutionStatus === 'working' || agentExecutionStatus === 'stopping', onChange: handleInputChange, onKeyDown: (e) => {
|
|
1105
1145
|
// If dropdown is visible, only handle escape to close it
|
|
1106
1146
|
if (isDropdownVisible) {
|
|
1107
1147
|
if (e.key === 'Escape') {
|
|
@@ -1115,7 +1155,7 @@ const ChatInput = ({ app, initialContent, placeholder, onSave, onCancel, isEditi
|
|
|
1115
1155
|
if (e.key === 'Enter' && !e.shiftKey) {
|
|
1116
1156
|
e.preventDefault();
|
|
1117
1157
|
adjustHeight(true);
|
|
1118
|
-
onSave(input, undefined,
|
|
1158
|
+
onSave(input, undefined, mapAdditionalContext());
|
|
1119
1159
|
// Reset
|
|
1120
1160
|
setInput('');
|
|
1121
1161
|
setAdditionalContext([]);
|
|
@@ -1132,7 +1172,7 @@ const ChatInput = ({ app, initialContent, placeholder, onSave, onCancel, isEditi
|
|
|
1132
1172
|
isDropdownVisible && (react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_ChatDropdown__WEBPACK_IMPORTED_MODULE_9__["default"], { options: expandedVariables, onSelect: handleOptionSelect, filterText: dropdownFilter, isDropdownFromButton: isDropdownFromButton, onFilterChange: setDropdownFilter, onClose: handleDropdownClose }))),
|
|
1133
1173
|
isEditing &&
|
|
1134
1174
|
react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", { className: "message-edit-buttons" },
|
|
1135
|
-
react__WEBPACK_IMPORTED_MODULE_0___default().createElement("button", { onClick: () => onSave(input, undefined,
|
|
1175
|
+
react__WEBPACK_IMPORTED_MODULE_0___default().createElement("button", { onClick: () => onSave(input, undefined, mapAdditionalContext()) }, "Save"),
|
|
1136
1176
|
react__WEBPACK_IMPORTED_MODULE_0___default().createElement("button", { onClick: onCancel }, "Cancel"))));
|
|
1137
1177
|
};
|
|
1138
1178
|
/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (ChatInput);
|
|
@@ -1193,7 +1233,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
1193
1233
|
|
|
1194
1234
|
|
|
1195
1235
|
|
|
1196
|
-
const ChatMessage = ({ app, message,
|
|
1236
|
+
const ChatMessage = ({ app, message, promptType, agentResponse, messageIndex, mitoAIConnectionError, mitoAIConnectionErrorType, notebookTracker, renderMimeRegistry, isLastAiMessage, isLastMessage, operatingSystem, previewAICode, acceptAICode, rejectAICode, onUpdateMessage, contextManager, codeReviewStatus, setNextSteps, agentModeEnabled, additionalContext, }) => {
|
|
1197
1237
|
const [isEditing, setIsEditing] = (0,react__WEBPACK_IMPORTED_MODULE_0__.useState)(false);
|
|
1198
1238
|
if (message.role !== 'user' && message.role !== 'assistant') {
|
|
1199
1239
|
return null;
|
|
@@ -1204,8 +1244,8 @@ const ChatMessage = ({ app, message, messageType, promptType, agentResponse, mes
|
|
|
1204
1244
|
const handleEditClick = () => {
|
|
1205
1245
|
setIsEditing(true);
|
|
1206
1246
|
};
|
|
1207
|
-
const handleSave = (content, _index,
|
|
1208
|
-
onUpdateMessage(messageIndex, content,
|
|
1247
|
+
const handleSave = (content, _index, additionalContext) => {
|
|
1248
|
+
onUpdateMessage(messageIndex, content, additionalContext);
|
|
1209
1249
|
setIsEditing(false);
|
|
1210
1250
|
};
|
|
1211
1251
|
const handleCancel = () => {
|
|
@@ -1237,7 +1277,6 @@ const ChatMessage = ({ app, message, messageType, promptType, agentResponse, mes
|
|
|
1237
1277
|
// Users end up applying the code in the middle of streaming and it gets very confusing
|
|
1238
1278
|
// very quickly for users.
|
|
1239
1279
|
let isCodeComplete = false;
|
|
1240
|
-
console.log(messageContentParts);
|
|
1241
1280
|
return (react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", { className: (0,_utils_classNames__WEBPACK_IMPORTED_MODULE_5__.classNames)("message", { "message-user": message.role === 'user' }, { 'message-assistant-chat': message.role === 'assistant' }) },
|
|
1242
1281
|
messageContentParts.map((messagePart, index) => {
|
|
1243
1282
|
var _a, _b;
|
|
@@ -1633,6 +1672,56 @@ const PythonCode = ({ code, renderMimeRegistry }) => {
|
|
|
1633
1672
|
/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (PythonCode);
|
|
1634
1673
|
|
|
1635
1674
|
|
|
1675
|
+
/***/ }),
|
|
1676
|
+
|
|
1677
|
+
/***/ "./lib/Extensions/AiChat/ChatMessage/RevertQuestionnaire.js":
|
|
1678
|
+
/*!******************************************************************!*\
|
|
1679
|
+
!*** ./lib/Extensions/AiChat/ChatMessage/RevertQuestionnaire.js ***!
|
|
1680
|
+
\******************************************************************/
|
|
1681
|
+
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
1682
|
+
|
|
1683
|
+
__webpack_require__.r(__webpack_exports__);
|
|
1684
|
+
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
1685
|
+
/* harmony export */ "default": () => (__WEBPACK_DEFAULT_EXPORT__)
|
|
1686
|
+
/* harmony export */ });
|
|
1687
|
+
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! react */ "webpack/sharing/consume/default/react");
|
|
1688
|
+
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_0__);
|
|
1689
|
+
/* harmony import */ var _components_TextButton__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../../../components/TextButton */ "./lib/components/TextButton.js");
|
|
1690
|
+
/* harmony import */ var _restAPI_RestAPI__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../../restAPI/RestAPI */ "./lib/restAPI/RestAPI.js");
|
|
1691
|
+
/* harmony import */ var _style_RevertQuestionnaire_css__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../../../../style/RevertQuestionnaire.css */ "./style/RevertQuestionnaire.css");
|
|
1692
|
+
/*
|
|
1693
|
+
* Copyright (c) Saga Inc.
|
|
1694
|
+
* Distributed under the terms of the GNU Affero General Public License v3.0 License.
|
|
1695
|
+
*/
|
|
1696
|
+
|
|
1697
|
+
|
|
1698
|
+
|
|
1699
|
+
|
|
1700
|
+
const RevertQuestionnaire = ({ onDestroy, getDuplicateChatHistoryManager, setChatHistoryManager }) => {
|
|
1701
|
+
const CHOICES = [
|
|
1702
|
+
'AI misunderstood me',
|
|
1703
|
+
'Code was buggy/incorrect',
|
|
1704
|
+
'Code was low quality',
|
|
1705
|
+
'I changed my mind about what I wanted'
|
|
1706
|
+
];
|
|
1707
|
+
const handleButtonClick = (choice) => {
|
|
1708
|
+
// Log the event
|
|
1709
|
+
void (0,_restAPI_RestAPI__WEBPACK_IMPORTED_MODULE_2__.logEvent)('mito_ai_revert_questionnaire_choice', { 'reason': choice });
|
|
1710
|
+
// Add a message to the chat history
|
|
1711
|
+
const newChatHistoryManager = getDuplicateChatHistoryManager();
|
|
1712
|
+
newChatHistoryManager.addAIMessageFromResponse("I've reverted all previous changes.", "chat", false);
|
|
1713
|
+
setChatHistoryManager(newChatHistoryManager);
|
|
1714
|
+
// Destroy the component (set showRevertQuestionnaire to false)
|
|
1715
|
+
onDestroy();
|
|
1716
|
+
};
|
|
1717
|
+
return (react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", { className: 'message revert-questionnaire-message' },
|
|
1718
|
+
react__WEBPACK_IMPORTED_MODULE_0___default().createElement("p", { className: 'revert-questionnaire-message-text' }, "What went wrong?"),
|
|
1719
|
+
CHOICES.map((choice) => (react__WEBPACK_IMPORTED_MODULE_0___default().createElement((react__WEBPACK_IMPORTED_MODULE_0___default().Fragment), null,
|
|
1720
|
+
react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_components_TextButton__WEBPACK_IMPORTED_MODULE_3__["default"], { text: choice, onClick: () => handleButtonClick(choice), title: choice, variant: 'gray', width: 'block', textAlign: 'left', className: "revert-questionnaire-button" }))))));
|
|
1721
|
+
};
|
|
1722
|
+
/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (RevertQuestionnaire);
|
|
1723
|
+
|
|
1724
|
+
|
|
1636
1725
|
/***/ }),
|
|
1637
1726
|
|
|
1638
1727
|
/***/ "./lib/Extensions/AiChat/ChatMessage/ScrollableSuggestions.js":
|
|
@@ -1773,12 +1862,12 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
1773
1862
|
/* harmony import */ var _components_AgentComponents_ErrorFixupToolUI__WEBPACK_IMPORTED_MODULE_28__ = __webpack_require__(/*! ../../components/AgentComponents/ErrorFixupToolUI */ "./lib/components/AgentComponents/ErrorFixupToolUI.js");
|
|
1774
1863
|
/* harmony import */ var _components_DropdownMenu__WEBPACK_IMPORTED_MODULE_24__ = __webpack_require__(/*! ../../components/DropdownMenu */ "./lib/components/DropdownMenu.js");
|
|
1775
1864
|
/* harmony import */ var _components_IconButton__WEBPACK_IMPORTED_MODULE_22__ = __webpack_require__(/*! ../../components/IconButton */ "./lib/components/IconButton.js");
|
|
1776
|
-
/* harmony import */ var
|
|
1865
|
+
/* harmony import */ var _components_LoadingCircle__WEBPACK_IMPORTED_MODULE_38__ = __webpack_require__(/*! ../../components/LoadingCircle */ "./lib/components/LoadingCircle.js");
|
|
1777
1866
|
/* harmony import */ var _components_LoadingDots__WEBPACK_IMPORTED_MODULE_30__ = __webpack_require__(/*! ../../components/LoadingDots */ "./lib/components/LoadingDots.js");
|
|
1778
1867
|
/* harmony import */ var _components_ModelSelector__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ../../components/ModelSelector */ "./lib/components/ModelSelector.js");
|
|
1779
|
-
/* harmony import */ var
|
|
1868
|
+
/* harmony import */ var _components_NextStepsPills__WEBPACK_IMPORTED_MODULE_35__ = __webpack_require__(/*! ../../components/NextStepsPills */ "./lib/components/NextStepsPills.js");
|
|
1780
1869
|
/* harmony import */ var _components_TextAndIconButton__WEBPACK_IMPORTED_MODULE_31__ = __webpack_require__(/*! ../../components/TextAndIconButton */ "./lib/components/TextAndIconButton.js");
|
|
1781
|
-
/* harmony import */ var
|
|
1870
|
+
/* harmony import */ var _components_ToggleButton__WEBPACK_IMPORTED_MODULE_37__ = __webpack_require__(/*! ../../components/ToggleButton */ "./lib/components/ToggleButton.js");
|
|
1782
1871
|
/* harmony import */ var _icons__WEBPACK_IMPORTED_MODULE_25__ = __webpack_require__(/*! ../../icons */ "./lib/icons/index.js");
|
|
1783
1872
|
/* harmony import */ var _icons_MitoLogo__WEBPACK_IMPORTED_MODULE_26__ = __webpack_require__(/*! ../../icons/MitoLogo */ "./lib/icons/MitoLogo.js");
|
|
1784
1873
|
/* harmony import */ var _icons_UndoIcon__WEBPACK_IMPORTED_MODULE_32__ = __webpack_require__(/*! ../../icons/UndoIcon */ "./lib/icons/UndoIcon.js");
|
|
@@ -1795,9 +1884,10 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
1795
1884
|
/* harmony import */ var _CTACarousel__WEBPACK_IMPORTED_MODULE_27__ = __webpack_require__(/*! ./CTACarousel */ "./lib/Extensions/AiChat/CTACarousel.js");
|
|
1796
1885
|
/* harmony import */ var _CodeDiffDisplay__WEBPACK_IMPORTED_MODULE_20__ = __webpack_require__(/*! ./CodeDiffDisplay */ "./lib/Extensions/AiChat/CodeDiffDisplay.js");
|
|
1797
1886
|
/* harmony import */ var _FirstMessage__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ./FirstMessage */ "./lib/Extensions/AiChat/FirstMessage.js");
|
|
1798
|
-
/* harmony import */ var
|
|
1887
|
+
/* harmony import */ var _ChatMessage_ChatInput__WEBPACK_IMPORTED_MODULE_36__ = __webpack_require__(/*! ./ChatMessage/ChatInput */ "./lib/Extensions/AiChat/ChatMessage/ChatInput.js");
|
|
1799
1888
|
/* harmony import */ var _ChatMessage_ChatMessage__WEBPACK_IMPORTED_MODULE_29__ = __webpack_require__(/*! ./ChatMessage/ChatMessage */ "./lib/Extensions/AiChat/ChatMessage/ChatMessage.js");
|
|
1800
|
-
/* harmony import */ var
|
|
1889
|
+
/* harmony import */ var _ChatMessage_RevertQuestionnaire__WEBPACK_IMPORTED_MODULE_33__ = __webpack_require__(/*! ./ChatMessage/RevertQuestionnaire */ "./lib/Extensions/AiChat/ChatMessage/RevertQuestionnaire.js");
|
|
1890
|
+
/* harmony import */ var _ChatMessage_ScrollableSuggestions__WEBPACK_IMPORTED_MODULE_34__ = __webpack_require__(/*! ./ChatMessage/ScrollableSuggestions */ "./lib/Extensions/AiChat/ChatMessage/ScrollableSuggestions.js");
|
|
1801
1891
|
/* harmony import */ var _ChatHistoryManager__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ./ChatHistoryManager */ "./lib/Extensions/AiChat/ChatHistoryManager.js");
|
|
1802
1892
|
/* harmony import */ var _style_button_css__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../../style/button.css */ "./style/button.css");
|
|
1803
1893
|
/* harmony import */ var _style_ChatTaskpane_css__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../../../style/ChatTaskpane.css */ "./style/ChatTaskpane.css");
|
|
@@ -1848,6 +1938,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
1848
1938
|
|
|
1849
1939
|
|
|
1850
1940
|
|
|
1941
|
+
|
|
1851
1942
|
// Styles
|
|
1852
1943
|
|
|
1853
1944
|
|
|
@@ -1915,6 +2006,8 @@ const ChatTaskpane = ({ notebookTracker, renderMimeRegistry, contextManager, app
|
|
|
1915
2006
|
const [displayedNextStepsIfAvailable, setDisplayedNextStepsIfAvailable] = (0,react__WEBPACK_IMPORTED_MODULE_1__.useState)(true);
|
|
1916
2007
|
// Track if checkpoint exists for UI updates
|
|
1917
2008
|
const [hasCheckpoint, setHasCheckpoint] = (0,react__WEBPACK_IMPORTED_MODULE_1__.useState)(false);
|
|
2009
|
+
// Track if revert questionnaire should be shown
|
|
2010
|
+
const [showRevertQuestionnaire, setShowRevertQuestionnaire] = (0,react__WEBPACK_IMPORTED_MODULE_1__.useState)(false);
|
|
1918
2011
|
const updateModelOnBackend = async (model) => {
|
|
1919
2012
|
try {
|
|
1920
2013
|
await websocketClient.sendMessage({
|
|
@@ -2020,6 +2113,8 @@ const ChatTaskpane = ({ notebookTracker, renderMimeRegistry, contextManager, app
|
|
|
2020
2113
|
}
|
|
2021
2114
|
// Clear next steps when starting a new chat
|
|
2022
2115
|
setNextSteps([]);
|
|
2116
|
+
// Get rid of the revert questionaire if its open
|
|
2117
|
+
setShowRevertQuestionnaire(false);
|
|
2023
2118
|
// Clear agent checkpoint when starting new chat
|
|
2024
2119
|
setHasCheckpoint(false);
|
|
2025
2120
|
// Enable follow mode when starting a new chat
|
|
@@ -2284,13 +2379,13 @@ const ChatTaskpane = ({ notebookTracker, renderMimeRegistry, contextManager, app
|
|
|
2284
2379
|
// Step 2: Send the message to the AI
|
|
2285
2380
|
await _sendMessageAndSaveResponse(completionRequest, newChatHistoryManager);
|
|
2286
2381
|
};
|
|
2287
|
-
const handleUpdateMessage = async (messageIndex, newContent) => {
|
|
2382
|
+
const handleUpdateMessage = async (messageIndex, newContent, additionalContext) => {
|
|
2288
2383
|
// Then send the new message to replace it
|
|
2289
2384
|
if (agentModeEnabled) {
|
|
2290
|
-
await startAgentExecution(newContent, messageIndex);
|
|
2385
|
+
await startAgentExecution(newContent, messageIndex, additionalContext);
|
|
2291
2386
|
}
|
|
2292
2387
|
else {
|
|
2293
|
-
await sendChatInputMessage(newContent, messageIndex);
|
|
2388
|
+
await sendChatInputMessage(newContent, messageIndex, additionalContext);
|
|
2294
2389
|
}
|
|
2295
2390
|
};
|
|
2296
2391
|
const _sendMessageAndSaveResponse = async (completionRequest, newChatHistoryManager) => {
|
|
@@ -2509,7 +2604,7 @@ const ChatTaskpane = ({ notebookTracker, renderMimeRegistry, contextManager, app
|
|
|
2509
2604
|
if (agentResponse.type === 'get_cell_output') {
|
|
2510
2605
|
// Mark that we should send the cell output to the agent
|
|
2511
2606
|
// in the next loop iteration
|
|
2512
|
-
sendCellIDOutput = agentResponse.
|
|
2607
|
+
sendCellIDOutput = agentResponse.get_cell_output_cell_id;
|
|
2513
2608
|
}
|
|
2514
2609
|
}
|
|
2515
2610
|
if (agentExecutionDepth > AGENT_EXECUTION_DEPTH_LIMIT) {
|
|
@@ -2582,6 +2677,7 @@ const ChatTaskpane = ({ notebookTracker, renderMimeRegistry, contextManager, app
|
|
|
2582
2677
|
*/
|
|
2583
2678
|
rejectAICode();
|
|
2584
2679
|
setNextSteps([]);
|
|
2680
|
+
setShowRevertQuestionnaire(false);
|
|
2585
2681
|
};
|
|
2586
2682
|
const rejectAICode = () => {
|
|
2587
2683
|
if (cellStateBeforeDiff.current === undefined) {
|
|
@@ -2815,7 +2911,7 @@ const ChatTaskpane = ({ notebookTracker, renderMimeRegistry, contextManager, app
|
|
|
2815
2911
|
return (react__WEBPACK_IMPORTED_MODULE_1___default().createElement(_components_AgentComponents_ErrorFixupToolUI__WEBPACK_IMPORTED_MODULE_28__["default"], { key: index, messages: displayOptimizedChat, renderMimeRegistry: renderMimeRegistry }));
|
|
2816
2912
|
}
|
|
2817
2913
|
else {
|
|
2818
|
-
return (react__WEBPACK_IMPORTED_MODULE_1___default().createElement(_ChatMessage_ChatMessage__WEBPACK_IMPORTED_MODULE_29__["default"], { key: index, message: displayOptimizedChat.message, promptType: displayOptimizedChat.promptType,
|
|
2914
|
+
return (react__WEBPACK_IMPORTED_MODULE_1___default().createElement(_ChatMessage_ChatMessage__WEBPACK_IMPORTED_MODULE_29__["default"], { key: index, message: displayOptimizedChat.message, promptType: displayOptimizedChat.promptType, agentResponse: displayOptimizedChat.agentResponse, codeCellID: displayOptimizedChat.codeCellID, mitoAIConnectionError: displayOptimizedChat.type === 'connection error', mitoAIConnectionErrorType: displayOptimizedChat.mitoAIConnectionErrorType || null, messageIndex: index, notebookTracker: notebookTracker, renderMimeRegistry: renderMimeRegistry, app: app, isLastAiMessage: index === lastAIMessagesIndex, isLastMessage: index === displayOptimizedChatHistory.length - 1, operatingSystem: operatingSystem, previewAICode: previewAICodeToActiveCell, acceptAICode: acceptAICode, rejectAICode: rejectAICode, onUpdateMessage: handleUpdateMessage, contextManager: contextManager, codeReviewStatus: codeReviewStatus, setNextSteps: setNextSteps, agentModeEnabled: agentModeEnabled, additionalContext: displayOptimizedChat.additionalContext }));
|
|
2819
2915
|
}
|
|
2820
2916
|
}).filter(message => message !== null),
|
|
2821
2917
|
loadingAIResponse &&
|
|
@@ -2826,10 +2922,17 @@ const ChatTaskpane = ({ notebookTracker, renderMimeRegistry, contextManager, app
|
|
|
2826
2922
|
agentModeEnabled &&
|
|
2827
2923
|
agentExecutionStatus === 'idle' &&
|
|
2828
2924
|
displayOptimizedChatHistory.length > 0 && (react__WEBPACK_IMPORTED_MODULE_1___default().createElement("div", { className: 'message message-assistant-chat' },
|
|
2829
|
-
react__WEBPACK_IMPORTED_MODULE_1___default().createElement(_components_TextAndIconButton__WEBPACK_IMPORTED_MODULE_31__["default"], { text: "Revert changes", icon: _icons_UndoIcon__WEBPACK_IMPORTED_MODULE_32__["default"], title: "Revert changes", onClick: () =>
|
|
2830
|
-
|
|
2925
|
+
react__WEBPACK_IMPORTED_MODULE_1___default().createElement(_components_TextAndIconButton__WEBPACK_IMPORTED_MODULE_31__["default"], { text: "Revert changes", icon: _icons_UndoIcon__WEBPACK_IMPORTED_MODULE_32__["default"], title: "Revert changes", onClick: () => {
|
|
2926
|
+
void (0,_utils_checkpoint__WEBPACK_IMPORTED_MODULE_14__.restoreCheckpoint)(app, notebookTracker, setHasCheckpoint);
|
|
2927
|
+
setDisplayedNextStepsIfAvailable(false);
|
|
2928
|
+
setHasCheckpoint(false);
|
|
2929
|
+
setShowRevertQuestionnaire(true);
|
|
2930
|
+
(0,_utils_scroll__WEBPACK_IMPORTED_MODULE_11__.scrollToDiv)(chatMessagesRef);
|
|
2931
|
+
}, variant: "gray", width: "fit-contents", iconPosition: "left" }),
|
|
2932
|
+
react__WEBPACK_IMPORTED_MODULE_1___default().createElement("p", { className: "text-muted text-sm" }, "Undo the most recent changes made by the agent"))),
|
|
2933
|
+
showRevertQuestionnaire && (react__WEBPACK_IMPORTED_MODULE_1___default().createElement(_ChatMessage_RevertQuestionnaire__WEBPACK_IMPORTED_MODULE_33__["default"], { onDestroy: () => setShowRevertQuestionnaire(false), getDuplicateChatHistoryManager: getDuplicateChatHistoryManager, setChatHistoryManager: setChatHistoryManager }))),
|
|
2831
2934
|
displayOptimizedChatHistory.length === 0 && (react__WEBPACK_IMPORTED_MODULE_1___default().createElement("div", { className: "suggestions-container" },
|
|
2832
|
-
react__WEBPACK_IMPORTED_MODULE_1___default().createElement(
|
|
2935
|
+
react__WEBPACK_IMPORTED_MODULE_1___default().createElement(_ChatMessage_ScrollableSuggestions__WEBPACK_IMPORTED_MODULE_34__["default"], { onSelectSuggestion: (prompt) => {
|
|
2833
2936
|
if (agentModeEnabled) {
|
|
2834
2937
|
void startAgentExecution(prompt);
|
|
2835
2938
|
}
|
|
@@ -2838,19 +2941,20 @@ const ChatTaskpane = ({ notebookTracker, renderMimeRegistry, contextManager, app
|
|
|
2838
2941
|
}
|
|
2839
2942
|
} }))),
|
|
2840
2943
|
react__WEBPACK_IMPORTED_MODULE_1___default().createElement("div", { className: `connected-input-container ${nextSteps.length > 0 ? 'has-next-steps' : ''}` },
|
|
2841
|
-
nextSteps.length > 0 && (react__WEBPACK_IMPORTED_MODULE_1___default().createElement(
|
|
2842
|
-
react__WEBPACK_IMPORTED_MODULE_1___default().createElement(
|
|
2944
|
+
nextSteps.length > 0 && (react__WEBPACK_IMPORTED_MODULE_1___default().createElement(_components_NextStepsPills__WEBPACK_IMPORTED_MODULE_35__["default"], { nextSteps: nextSteps, onSelectNextStep: agentModeEnabled ? startAgentExecution : sendChatInputMessage, displayedNextStepsIfAvailable: displayedNextStepsIfAvailable, setDisplayedNextStepsIfAvailable: setDisplayedNextStepsIfAvailable })),
|
|
2945
|
+
react__WEBPACK_IMPORTED_MODULE_1___default().createElement(_ChatMessage_ChatInput__WEBPACK_IMPORTED_MODULE_36__["default"], { app: app, initialContent: '', placeholder: agentExecutionStatus === 'working' ? 'Agent is working...' :
|
|
2843
2946
|
agentExecutionStatus === 'stopping' ? 'Agent is stopping...' :
|
|
2844
2947
|
agentModeEnabled ? 'Ask agent to do anything' :
|
|
2845
2948
|
displayOptimizedChatHistory.length < 2 ? `Ask question (${operatingSystem === 'mac' ? '⌘' : 'Ctrl'}E), @ to mention`
|
|
2846
|
-
: `Ask followup (${operatingSystem === 'mac' ? '⌘' : 'Ctrl'}E), @ to mention`, onSave: agentModeEnabled ? startAgentExecution : sendChatInputMessage, onCancel: undefined, isEditing: false, contextManager: contextManager, notebookTracker: notebookTracker, renderMimeRegistry: renderMimeRegistry, agentModeEnabled: agentModeEnabled })),
|
|
2949
|
+
: `Ask followup (${operatingSystem === 'mac' ? '⌘' : 'Ctrl'}E), @ to mention`, onSave: agentModeEnabled ? startAgentExecution : sendChatInputMessage, onCancel: undefined, isEditing: false, contextManager: contextManager, notebookTracker: notebookTracker, renderMimeRegistry: renderMimeRegistry, agentModeEnabled: agentModeEnabled, agentExecutionStatus: agentExecutionStatus })),
|
|
2847
2950
|
agentExecutionStatus !== 'working' && agentExecutionStatus !== 'stopping' && (react__WEBPACK_IMPORTED_MODULE_1___default().createElement("div", { className: "chat-controls" },
|
|
2848
2951
|
react__WEBPACK_IMPORTED_MODULE_1___default().createElement("div", { className: "chat-controls-left" },
|
|
2849
|
-
react__WEBPACK_IMPORTED_MODULE_1___default().createElement(
|
|
2952
|
+
react__WEBPACK_IMPORTED_MODULE_1___default().createElement(_components_ToggleButton__WEBPACK_IMPORTED_MODULE_37__["default"], { leftText: "Chat", leftTooltip: "Chat mode suggests an edit to the active cell and let's you decide to accept or reject it.", rightText: "Agent", rightTooltip: "Agent mode writes and executes code until it's finished your request.", isLeftSelected: !agentModeEnabled, onChange: async (isLeftSelected) => {
|
|
2850
2953
|
await startNewChat(); // TODO: delete thread instead of starting new chat
|
|
2851
2954
|
setAgentModeEnabled(!isLeftSelected);
|
|
2852
2955
|
// Clear agent checkpoint when switching modes
|
|
2853
2956
|
setHasCheckpoint(false);
|
|
2957
|
+
setShowRevertQuestionnaire(false);
|
|
2854
2958
|
// Focus the chat input directly
|
|
2855
2959
|
const chatInput = document.querySelector('.chat-input');
|
|
2856
2960
|
if (chatInput) {
|
|
@@ -2881,7 +2985,7 @@ const ChatTaskpane = ({ notebookTracker, renderMimeRegistry, contextManager, app
|
|
|
2881
2985
|
" \u23CE"))),
|
|
2882
2986
|
(agentExecutionStatus === 'working' || agentExecutionStatus === 'stopping') && (react__WEBPACK_IMPORTED_MODULE_1___default().createElement("button", { className: "button-base button-red stop-agent-button", onClick: markAgentForStopping, disabled: agentExecutionStatus === 'stopping', "data-testid": "stop-agent-button" }, agentExecutionStatus === 'stopping' ? (react__WEBPACK_IMPORTED_MODULE_1___default().createElement("div", { className: "stop-agent-button-content" },
|
|
2883
2987
|
"Stopping",
|
|
2884
|
-
react__WEBPACK_IMPORTED_MODULE_1___default().createElement(
|
|
2988
|
+
react__WEBPACK_IMPORTED_MODULE_1___default().createElement(_components_LoadingCircle__WEBPACK_IMPORTED_MODULE_38__["default"], null),
|
|
2885
2989
|
" ")) : ('Stop Agent')))));
|
|
2886
2990
|
};
|
|
2887
2991
|
/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (ChatTaskpane);
|
|
@@ -3430,8 +3534,6 @@ const convertNotebookToStreamlit = async (notebookTracker, appBuilderService) =>
|
|
|
3430
3534
|
}
|
|
3431
3535
|
const notebookPath = notebookPanel.context.path;
|
|
3432
3536
|
const notebookName = _jupyterlab_coreutils__WEBPACK_IMPORTED_MODULE_0__.PathExt.basename(notebookPath, '.ipynb');
|
|
3433
|
-
// Get full path to folder
|
|
3434
|
-
const pathToFolder = _jupyterlab_coreutils__WEBPACK_IMPORTED_MODULE_0__.PathExt.dirname(notebookPath);
|
|
3435
3537
|
console.log('Notebook path:', notebookPath);
|
|
3436
3538
|
console.log('Notebook name:', notebookName);
|
|
3437
3539
|
console.log('Current working directory info:', notebookPanel.context);
|
|
@@ -3450,7 +3552,6 @@ const convertNotebookToStreamlit = async (notebookTracker, appBuilderService) =>
|
|
|
3450
3552
|
type: 'build-app',
|
|
3451
3553
|
message_id: _lumino_coreutils__WEBPACK_IMPORTED_MODULE_1__.UUID.uuid4(),
|
|
3452
3554
|
notebook_path: notebookPath,
|
|
3453
|
-
app_path: pathToFolder,
|
|
3454
3555
|
jwt_token: jwtToken || appBuilderService.client.serverSettings.token
|
|
3455
3556
|
});
|
|
3456
3557
|
console.log("App deployment response:", response);
|
|
@@ -5572,6 +5673,142 @@ const SupportPage = () => {
|
|
|
5572
5673
|
};
|
|
5573
5674
|
|
|
5574
5675
|
|
|
5676
|
+
/***/ }),
|
|
5677
|
+
|
|
5678
|
+
/***/ "./lib/Extensions/StreamlitPreview/StreamlitPreviewPlugin.js":
|
|
5679
|
+
/*!*******************************************************************!*\
|
|
5680
|
+
!*** ./lib/Extensions/StreamlitPreview/StreamlitPreviewPlugin.js ***!
|
|
5681
|
+
\*******************************************************************/
|
|
5682
|
+
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
5683
|
+
|
|
5684
|
+
__webpack_require__.r(__webpack_exports__);
|
|
5685
|
+
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
5686
|
+
/* harmony export */ "default": () => (__WEBPACK_DEFAULT_EXPORT__)
|
|
5687
|
+
/* harmony export */ });
|
|
5688
|
+
/* harmony import */ var _jupyterlab_notebook__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @jupyterlab/notebook */ "webpack/sharing/consume/default/@jupyterlab/notebook");
|
|
5689
|
+
/* harmony import */ var _jupyterlab_notebook__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_jupyterlab_notebook__WEBPACK_IMPORTED_MODULE_0__);
|
|
5690
|
+
/* harmony import */ var _jupyterlab_apputils__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @jupyterlab/apputils */ "webpack/sharing/consume/default/@jupyterlab/apputils");
|
|
5691
|
+
/* harmony import */ var _jupyterlab_apputils__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_jupyterlab_apputils__WEBPACK_IMPORTED_MODULE_1__);
|
|
5692
|
+
/* harmony import */ var _jupyterlab_coreutils__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @jupyterlab/coreutils */ "webpack/sharing/consume/default/@jupyterlab/coreutils");
|
|
5693
|
+
/* harmony import */ var _jupyterlab_coreutils__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_jupyterlab_coreutils__WEBPACK_IMPORTED_MODULE_2__);
|
|
5694
|
+
/* harmony import */ var _lumino_widgets__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @lumino/widgets */ "webpack/sharing/consume/default/@lumino/widgets");
|
|
5695
|
+
/* harmony import */ var _lumino_widgets__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_lumino_widgets__WEBPACK_IMPORTED_MODULE_3__);
|
|
5696
|
+
/* harmony import */ var _AiChat_token__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../AiChat/token */ "./lib/Extensions/AiChat/token.js");
|
|
5697
|
+
/* harmony import */ var _restAPI_RestAPI__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../../restAPI/RestAPI */ "./lib/restAPI/RestAPI.js");
|
|
5698
|
+
/* harmony import */ var _commands__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../../commands */ "./lib/commands.js");
|
|
5699
|
+
/*
|
|
5700
|
+
* Copyright (c) Saga Inc.
|
|
5701
|
+
* Distributed under the terms of the GNU Affero General Public License v3.0 License.
|
|
5702
|
+
*/
|
|
5703
|
+
|
|
5704
|
+
|
|
5705
|
+
|
|
5706
|
+
|
|
5707
|
+
|
|
5708
|
+
|
|
5709
|
+
|
|
5710
|
+
|
|
5711
|
+
|
|
5712
|
+
/**
|
|
5713
|
+
* Simple HTML widget for displaying iframe content.
|
|
5714
|
+
*/
|
|
5715
|
+
class IFrameWidget extends _lumino_widgets__WEBPACK_IMPORTED_MODULE_3__.Widget {
|
|
5716
|
+
constructor(url) {
|
|
5717
|
+
super();
|
|
5718
|
+
this.addClass('jp-iframe-widget');
|
|
5719
|
+
const iframe = document.createElement('iframe');
|
|
5720
|
+
iframe.src = url;
|
|
5721
|
+
iframe.style.width = '100%';
|
|
5722
|
+
iframe.style.height = '100%';
|
|
5723
|
+
iframe.style.border = 'none';
|
|
5724
|
+
this.node.appendChild(iframe);
|
|
5725
|
+
}
|
|
5726
|
+
setUrl(url) {
|
|
5727
|
+
const iframe = this.node.querySelector('iframe');
|
|
5728
|
+
if (iframe) {
|
|
5729
|
+
iframe.src = url;
|
|
5730
|
+
}
|
|
5731
|
+
}
|
|
5732
|
+
}
|
|
5733
|
+
/**
|
|
5734
|
+
* The streamlit preview plugin.
|
|
5735
|
+
*/
|
|
5736
|
+
const StreamlitPreviewPlugin = {
|
|
5737
|
+
id: 'mito-ai:streamlit-preview',
|
|
5738
|
+
autoStart: true,
|
|
5739
|
+
requires: [_jupyterlab_notebook__WEBPACK_IMPORTED_MODULE_0__.INotebookTracker, _jupyterlab_apputils__WEBPACK_IMPORTED_MODULE_1__.ICommandPalette, _AiChat_token__WEBPACK_IMPORTED_MODULE_4__.IChatTracker],
|
|
5740
|
+
activate: (app, notebookTracker, palette) => {
|
|
5741
|
+
console.log('mito-ai: StreamlitPreviewPlugin activated');
|
|
5742
|
+
// Add command to command palette
|
|
5743
|
+
app.commands.addCommand(_commands__WEBPACK_IMPORTED_MODULE_5__.previewAsStreamlit, {
|
|
5744
|
+
label: 'Preview as Streamlit',
|
|
5745
|
+
caption: 'Convert current notebook to Streamlit app and preview it',
|
|
5746
|
+
execute: async () => {
|
|
5747
|
+
await previewNotebookAsStreamlit(app, notebookTracker);
|
|
5748
|
+
}
|
|
5749
|
+
});
|
|
5750
|
+
// Add to command palette
|
|
5751
|
+
palette.addItem({
|
|
5752
|
+
command: _commands__WEBPACK_IMPORTED_MODULE_5__.previewAsStreamlit,
|
|
5753
|
+
category: 'Mito AI'
|
|
5754
|
+
});
|
|
5755
|
+
}
|
|
5756
|
+
};
|
|
5757
|
+
/**
|
|
5758
|
+
* Preview the current notebook as a Streamlit app.
|
|
5759
|
+
*/
|
|
5760
|
+
async function previewNotebookAsStreamlit(app, notebookTracker) {
|
|
5761
|
+
const notebookPanel = notebookTracker.currentWidget;
|
|
5762
|
+
if (!notebookPanel) {
|
|
5763
|
+
_jupyterlab_apputils__WEBPACK_IMPORTED_MODULE_1__.Notification.error('No notebook is currently active');
|
|
5764
|
+
return;
|
|
5765
|
+
}
|
|
5766
|
+
// First save the notebook to ensure the app is up to date
|
|
5767
|
+
await notebookPanel.context.save();
|
|
5768
|
+
const notebookPath = notebookPanel.context.path;
|
|
5769
|
+
const notebookName = _jupyterlab_coreutils__WEBPACK_IMPORTED_MODULE_2__.PathExt.basename(notebookPath, '.ipynb');
|
|
5770
|
+
// Show building notification
|
|
5771
|
+
const notificationId = _jupyterlab_apputils__WEBPACK_IMPORTED_MODULE_1__.Notification.emit('Building App Preview...', 'in-progress', { autoClose: false });
|
|
5772
|
+
try {
|
|
5773
|
+
const previewData = await (0,_restAPI_RestAPI__WEBPACK_IMPORTED_MODULE_6__.startStreamlitPreview)(notebookPath);
|
|
5774
|
+
// Create iframe widget
|
|
5775
|
+
const iframeWidget = new IFrameWidget(previewData.url);
|
|
5776
|
+
// Create main area widget
|
|
5777
|
+
const widget = new _jupyterlab_apputils__WEBPACK_IMPORTED_MODULE_1__.MainAreaWidget({ content: iframeWidget });
|
|
5778
|
+
widget.title.label = `App Preview (${notebookName})`;
|
|
5779
|
+
widget.title.closable = true;
|
|
5780
|
+
// Handle widget disposal
|
|
5781
|
+
widget.disposed.connect(() => {
|
|
5782
|
+
console.log('Widget disposed, stopping preview');
|
|
5783
|
+
void (0,_restAPI_RestAPI__WEBPACK_IMPORTED_MODULE_6__.stopStreamlitPreview)(previewData.id);
|
|
5784
|
+
});
|
|
5785
|
+
// Add widget to main area with split-right mode
|
|
5786
|
+
app.shell.add(widget, 'main', {
|
|
5787
|
+
mode: 'split-right',
|
|
5788
|
+
ref: notebookPanel.id
|
|
5789
|
+
});
|
|
5790
|
+
// Update notification to success
|
|
5791
|
+
_jupyterlab_apputils__WEBPACK_IMPORTED_MODULE_1__.Notification.update({
|
|
5792
|
+
id: notificationId,
|
|
5793
|
+
message: 'Streamlit preview started successfully!',
|
|
5794
|
+
type: 'default',
|
|
5795
|
+
autoClose: false
|
|
5796
|
+
});
|
|
5797
|
+
}
|
|
5798
|
+
catch (error) {
|
|
5799
|
+
console.error('Error starting streamlit preview:', error);
|
|
5800
|
+
// Update notification to error
|
|
5801
|
+
_jupyterlab_apputils__WEBPACK_IMPORTED_MODULE_1__.Notification.update({
|
|
5802
|
+
id: notificationId,
|
|
5803
|
+
message: `Failed to start preview: ${error instanceof Error ? error.message : 'Unknown error'}`,
|
|
5804
|
+
type: 'error',
|
|
5805
|
+
autoClose: false
|
|
5806
|
+
});
|
|
5807
|
+
}
|
|
5808
|
+
}
|
|
5809
|
+
/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (StreamlitPreviewPlugin);
|
|
5810
|
+
|
|
5811
|
+
|
|
5575
5812
|
/***/ }),
|
|
5576
5813
|
|
|
5577
5814
|
/***/ "./lib/Extensions/ToolbarButtons/ToolbarButtonsPlugin.js":
|
|
@@ -5672,6 +5909,17 @@ const ToolbarButtonsPlugin = {
|
|
|
5672
5909
|
return app.commands.hasCommand(_commands__WEBPACK_IMPORTED_MODULE_3__.COMMAND_MITO_AI_BETA_MODE_ENABLED);
|
|
5673
5910
|
}
|
|
5674
5911
|
});
|
|
5912
|
+
commands.addCommand('toolbar-button:preview-as-streamlit', {
|
|
5913
|
+
label: 'Preview App',
|
|
5914
|
+
caption: 'Preview as Streamlit',
|
|
5915
|
+
className: 'text-button-mito-ai button-base button-purple button-small',
|
|
5916
|
+
execute: async () => {
|
|
5917
|
+
void app.commands.execute('mito-ai:preview-as-streamlit');
|
|
5918
|
+
},
|
|
5919
|
+
isVisible: () => {
|
|
5920
|
+
return app.commands.hasCommand(_commands__WEBPACK_IMPORTED_MODULE_3__.COMMAND_MITO_AI_BETA_MODE_ENABLED);
|
|
5921
|
+
}
|
|
5922
|
+
});
|
|
5675
5923
|
// Check if the beta mode is enabled. After checking, tell Jupyter to
|
|
5676
5924
|
// re-evaluate convert-to-streamlit visibility now that we have had the
|
|
5677
5925
|
// opportunity to set the mito-ai:beta-mode-enabled command if beta mode is enabled.
|
|
@@ -5680,6 +5928,7 @@ const ToolbarButtonsPlugin = {
|
|
|
5680
5928
|
commands.addCommand(_commands__WEBPACK_IMPORTED_MODULE_3__.COMMAND_MITO_AI_BETA_MODE_ENABLED, { execute: () => { } });
|
|
5681
5929
|
commands.notifyCommandChanged('toolbar-button:convert-to-streamlit');
|
|
5682
5930
|
commands.notifyCommandChanged('toolbar-button:toggle-include-cell-in-app');
|
|
5931
|
+
commands.notifyCommandChanged('toolbar-button:preview-as-streamlit');
|
|
5683
5932
|
}
|
|
5684
5933
|
}).catch(error => {
|
|
5685
5934
|
console.error('Error checking beta mode:', error);
|
|
@@ -6177,7 +6426,8 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
6177
6426
|
/* harmony export */ COMMAND_MITO_AI_SEND_AGENT_MESSAGE: () => (/* binding */ COMMAND_MITO_AI_SEND_AGENT_MESSAGE),
|
|
6178
6427
|
/* harmony export */ COMMAND_MITO_AI_SEND_DEBUG_ERROR_MESSAGE: () => (/* binding */ COMMAND_MITO_AI_SEND_DEBUG_ERROR_MESSAGE),
|
|
6179
6428
|
/* harmony export */ COMMAND_MITO_AI_SEND_EXPLAIN_CODE_MESSAGE: () => (/* binding */ COMMAND_MITO_AI_SEND_EXPLAIN_CODE_MESSAGE),
|
|
6180
|
-
/* harmony export */ COMMAND_MITO_AI_SEND_MESSAGE: () => (/* binding */ COMMAND_MITO_AI_SEND_MESSAGE)
|
|
6429
|
+
/* harmony export */ COMMAND_MITO_AI_SEND_MESSAGE: () => (/* binding */ COMMAND_MITO_AI_SEND_MESSAGE),
|
|
6430
|
+
/* harmony export */ previewAsStreamlit: () => (/* binding */ previewAsStreamlit)
|
|
6181
6431
|
/* harmony export */ });
|
|
6182
6432
|
/*
|
|
6183
6433
|
* Copyright (c) Saga Inc.
|
|
@@ -6196,6 +6446,8 @@ const COMMAND_MITO_AI_CELL_TOOLBAR_ACCEPT_CODE = `toolbar-button:accept-code`;
|
|
|
6196
6446
|
const COMMAND_MITO_AI_CELL_TOOLBAR_REJECT_CODE = `toolbar-button:reject-code`;
|
|
6197
6447
|
// Beta mode commands
|
|
6198
6448
|
const COMMAND_MITO_AI_BETA_MODE_ENABLED = `${MITO_AI}:beta-mode-enabled`;
|
|
6449
|
+
// Streamlit commands
|
|
6450
|
+
const previewAsStreamlit = 'mito-ai:preview-as-streamlit';
|
|
6199
6451
|
|
|
6200
6452
|
|
|
6201
6453
|
/***/ }),
|
|
@@ -6885,12 +7137,12 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
6885
7137
|
|
|
6886
7138
|
|
|
6887
7139
|
|
|
6888
|
-
const TextButton = ({ text, onClick, title, variant, width, action }) => {
|
|
7140
|
+
const TextButton = ({ text, onClick, title, variant, width, action, textAlign = 'center', className }) => {
|
|
6889
7141
|
if (action) {
|
|
6890
7142
|
return (react__WEBPACK_IMPORTED_MODULE_0___default().createElement("form", { action: action, method: "POST", target: "_blank" },
|
|
6891
|
-
react__WEBPACK_IMPORTED_MODULE_0___default().createElement("button", { className: (0,_utils_classNames__WEBPACK_IMPORTED_MODULE_3__.classNames)("text-button-mito-ai", "button-base", `button-${variant}`, `button-width-${width}`), onClick: onClick, title: title }, text)));
|
|
7143
|
+
react__WEBPACK_IMPORTED_MODULE_0___default().createElement("button", { className: (0,_utils_classNames__WEBPACK_IMPORTED_MODULE_3__.classNames)("text-button-mito-ai", "button-base", `button-${variant}`, `button-width-${width}`, `text-align-${textAlign}`, className), onClick: onClick, title: title }, text)));
|
|
6892
7144
|
}
|
|
6893
|
-
return (react__WEBPACK_IMPORTED_MODULE_0___default().createElement("button", { className: (0,_utils_classNames__WEBPACK_IMPORTED_MODULE_3__.classNames)("text-button-mito-ai", "button-base", `button-${variant}`, `button-width-${width}`), onClick: onClick, title: title }, text));
|
|
7145
|
+
return (react__WEBPACK_IMPORTED_MODULE_0___default().createElement("button", { className: (0,_utils_classNames__WEBPACK_IMPORTED_MODULE_3__.classNames)("text-button-mito-ai", "button-base", `button-${variant}`, `button-width-${width}`, `text-align-${textAlign}`, className), onClick: onClick, title: title }, text));
|
|
6894
7146
|
};
|
|
6895
7147
|
/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (TextButton);
|
|
6896
7148
|
|
|
@@ -7515,13 +7767,14 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
7515
7767
|
/* harmony import */ var _Extensions_AiChat_AiChatPlugin__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./Extensions/AiChat/AiChatPlugin */ "./lib/Extensions/AiChat/AiChatPlugin.js");
|
|
7516
7768
|
/* harmony import */ var _Extensions_ContextManager_ContextManagerPlugin__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./Extensions/ContextManager/ContextManagerPlugin */ "./lib/Extensions/ContextManager/ContextManagerPlugin.js");
|
|
7517
7769
|
/* harmony import */ var _Extensions_ErrorMimeRenderer_ErrorMimeRendererPlugin__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./Extensions/ErrorMimeRenderer/ErrorMimeRendererPlugin */ "./lib/Extensions/ErrorMimeRenderer/ErrorMimeRendererPlugin.js");
|
|
7518
|
-
/* harmony import */ var
|
|
7770
|
+
/* harmony import */ var _Extensions_ToolbarButtons_ToolbarButtonsPlugin__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./Extensions/ToolbarButtons/ToolbarButtonsPlugin */ "./lib/Extensions/ToolbarButtons/ToolbarButtonsPlugin.js");
|
|
7519
7771
|
/* harmony import */ var _Extensions_AppBuilder_AppBuilderPlugin__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./Extensions/AppBuilder/AppBuilderPlugin */ "./lib/Extensions/AppBuilder/AppBuilderPlugin.js");
|
|
7520
|
-
/* harmony import */ var
|
|
7521
|
-
/* harmony import */ var
|
|
7522
|
-
/* harmony import */ var
|
|
7523
|
-
/* harmony import */ var
|
|
7524
|
-
/* harmony import */ var
|
|
7772
|
+
/* harmony import */ var _Extensions_StreamlitPreview_StreamlitPreviewPlugin__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./Extensions/StreamlitPreview/StreamlitPreviewPlugin */ "./lib/Extensions/StreamlitPreview/StreamlitPreviewPlugin.js");
|
|
7773
|
+
/* harmony import */ var _Extensions_emptyCell_EmptyCellPlugin__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./Extensions/emptyCell/EmptyCellPlugin */ "./lib/Extensions/emptyCell/EmptyCellPlugin.js");
|
|
7774
|
+
/* harmony import */ var _Extensions_status__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ./Extensions/status */ "./lib/Extensions/status/index.js");
|
|
7775
|
+
/* harmony import */ var _Extensions_SettingsManager_SettingsManagerPlugin__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ./Extensions/SettingsManager/SettingsManagerPlugin */ "./lib/Extensions/SettingsManager/SettingsManagerPlugin.js");
|
|
7776
|
+
/* harmony import */ var _Extensions_VersionCheck__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ./Extensions/VersionCheck */ "./lib/Extensions/VersionCheck/index.js");
|
|
7777
|
+
/* harmony import */ var _Extensions_NotebookFooter__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! ./Extensions/NotebookFooter */ "./lib/Extensions/NotebookFooter/index.js");
|
|
7525
7778
|
/*
|
|
7526
7779
|
* Copyright (c) Saga Inc.
|
|
7527
7780
|
* Distributed under the terms of the GNU Affero General Public License v3.0 License.
|
|
@@ -7536,6 +7789,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
7536
7789
|
|
|
7537
7790
|
|
|
7538
7791
|
|
|
7792
|
+
|
|
7539
7793
|
// This is the main entry point to the mito-ai extension. It must export all of the top level
|
|
7540
7794
|
// extensions that we want to load.
|
|
7541
7795
|
/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = ([
|
|
@@ -7543,12 +7797,13 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
7543
7797
|
_Extensions_ErrorMimeRenderer_ErrorMimeRendererPlugin__WEBPACK_IMPORTED_MODULE_1__["default"],
|
|
7544
7798
|
_Extensions_ContextManager_ContextManagerPlugin__WEBPACK_IMPORTED_MODULE_2__["default"],
|
|
7545
7799
|
_Extensions_AppBuilder_AppBuilderPlugin__WEBPACK_IMPORTED_MODULE_3__["default"],
|
|
7546
|
-
|
|
7547
|
-
|
|
7548
|
-
|
|
7549
|
-
|
|
7550
|
-
|
|
7551
|
-
|
|
7800
|
+
_Extensions_StreamlitPreview_StreamlitPreviewPlugin__WEBPACK_IMPORTED_MODULE_4__["default"],
|
|
7801
|
+
_Extensions_ToolbarButtons_ToolbarButtonsPlugin__WEBPACK_IMPORTED_MODULE_5__["default"],
|
|
7802
|
+
_Extensions_emptyCell_EmptyCellPlugin__WEBPACK_IMPORTED_MODULE_6__.emptyCellPlaceholder,
|
|
7803
|
+
_Extensions_status__WEBPACK_IMPORTED_MODULE_7__.statusItem,
|
|
7804
|
+
_Extensions_SettingsManager_SettingsManagerPlugin__WEBPACK_IMPORTED_MODULE_8__["default"],
|
|
7805
|
+
_Extensions_VersionCheck__WEBPACK_IMPORTED_MODULE_9__.versionCheckPlugin,
|
|
7806
|
+
_Extensions_NotebookFooter__WEBPACK_IMPORTED_MODULE_10__["default"]
|
|
7552
7807
|
]);
|
|
7553
7808
|
|
|
7554
7809
|
|
|
@@ -7568,6 +7823,8 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
7568
7823
|
/* harmony export */ getSetting: () => (/* binding */ getSetting),
|
|
7569
7824
|
/* harmony export */ logEvent: () => (/* binding */ logEvent),
|
|
7570
7825
|
/* harmony export */ setRule: () => (/* binding */ setRule),
|
|
7826
|
+
/* harmony export */ startStreamlitPreview: () => (/* binding */ startStreamlitPreview),
|
|
7827
|
+
/* harmony export */ stopStreamlitPreview: () => (/* binding */ stopStreamlitPreview),
|
|
7571
7828
|
/* harmony export */ updateSettings: () => (/* binding */ updateSettings)
|
|
7572
7829
|
/* harmony export */ });
|
|
7573
7830
|
/* harmony import */ var _utils__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./utils */ "./lib/restAPI/utils.js");
|
|
@@ -7658,6 +7915,29 @@ const getDatabaseConnections = async () => {
|
|
|
7658
7915
|
}
|
|
7659
7916
|
return resp.data || {};
|
|
7660
7917
|
};
|
|
7918
|
+
/************************************
|
|
7919
|
+
|
|
7920
|
+
STREAMLIT PREVIEW ENDPOINTS
|
|
7921
|
+
|
|
7922
|
+
************************************/
|
|
7923
|
+
const startStreamlitPreview = async (notebookPath) => {
|
|
7924
|
+
const response = await (0,_utils__WEBPACK_IMPORTED_MODULE_0__.requestAPI)('streamlit-preview', {
|
|
7925
|
+
method: 'POST',
|
|
7926
|
+
body: JSON.stringify({ notebook_path: notebookPath }),
|
|
7927
|
+
});
|
|
7928
|
+
if (response.error) {
|
|
7929
|
+
throw new Error(response.error.message);
|
|
7930
|
+
}
|
|
7931
|
+
return response.data;
|
|
7932
|
+
};
|
|
7933
|
+
const stopStreamlitPreview = async (previewId) => {
|
|
7934
|
+
const response = await (0,_utils__WEBPACK_IMPORTED_MODULE_0__.requestAPI)(`streamlit-preview/${previewId}`, {
|
|
7935
|
+
method: 'DELETE',
|
|
7936
|
+
});
|
|
7937
|
+
if (response.error) {
|
|
7938
|
+
throw new Error(response.error.message);
|
|
7939
|
+
}
|
|
7940
|
+
};
|
|
7661
7941
|
|
|
7662
7942
|
|
|
7663
7943
|
/***/ }),
|
|
@@ -8080,11 +8360,13 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
8080
8360
|
/* harmony export */ restoreCheckpoint: () => (/* binding */ restoreCheckpoint)
|
|
8081
8361
|
/* harmony export */ });
|
|
8082
8362
|
/* harmony import */ var _notebook__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./notebook */ "./lib/utils/notebook.js");
|
|
8363
|
+
/* harmony import */ var _restAPI_RestAPI__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../restAPI/RestAPI */ "./lib/restAPI/RestAPI.js");
|
|
8083
8364
|
/*
|
|
8084
8365
|
* Copyright (c) Saga Inc.
|
|
8085
8366
|
* Distributed under the terms of the GNU Affero General Public License v3.0 License.
|
|
8086
8367
|
*/
|
|
8087
8368
|
|
|
8369
|
+
|
|
8088
8370
|
const createCheckpoint = async (app, setHasCheckpoint) => {
|
|
8089
8371
|
// By saving the notebook, we create a checkpoint that we can restore from
|
|
8090
8372
|
await app.commands.execute("docmanager:save");
|
|
@@ -8099,7 +8381,7 @@ const getNotebookStateHash = (notebookTracker) => {
|
|
|
8099
8381
|
const notebookState = cells.map(cell => `${cell.id}:${cell.code}`).join('|');
|
|
8100
8382
|
return notebookState;
|
|
8101
8383
|
};
|
|
8102
|
-
const restoreCheckpoint = async (app, notebookTracker, setHasCheckpoint
|
|
8384
|
+
const restoreCheckpoint = async (app, notebookTracker, setHasCheckpoint) => {
|
|
8103
8385
|
// Get the notebook state before attempting restoration
|
|
8104
8386
|
const notebookStateBefore = getNotebookStateHash(notebookTracker);
|
|
8105
8387
|
// Restore the checkpoint
|
|
@@ -8113,10 +8395,8 @@ const restoreCheckpoint = async (app, notebookTracker, setHasCheckpoint, getDupl
|
|
|
8113
8395
|
}
|
|
8114
8396
|
// The restoration was successful, so update the state
|
|
8115
8397
|
setHasCheckpoint(false);
|
|
8116
|
-
//
|
|
8117
|
-
|
|
8118
|
-
newChatHistoryManager.addAIMessageFromResponse("I've reverted all previous changes", "chat", false);
|
|
8119
|
-
setChatHistoryManager(newChatHistoryManager);
|
|
8398
|
+
// Log the checkpoint restoration
|
|
8399
|
+
void (0,_restAPI_RestAPI__WEBPACK_IMPORTED_MODULE_1__.logEvent)('mito_ai_checkpoint_restored', {});
|
|
8120
8400
|
// Restart the run all
|
|
8121
8401
|
await app.commands.execute("notebook:restart-run-all");
|
|
8122
8402
|
};
|
|
@@ -10381,7 +10661,24 @@ ___CSS_LOADER_EXPORT___.push([module.id, `/*
|
|
|
10381
10661
|
|
|
10382
10662
|
.context-button:hover {
|
|
10383
10663
|
background-color: var(--jp-layout-color3);
|
|
10384
|
-
}
|
|
10664
|
+
}
|
|
10665
|
+
|
|
10666
|
+
/* Disabled state styles */
|
|
10667
|
+
.chat-input:disabled {
|
|
10668
|
+
opacity: 0.6;
|
|
10669
|
+
cursor: not-allowed;
|
|
10670
|
+
background-color: var(--jp-layout-color2);
|
|
10671
|
+
}
|
|
10672
|
+
|
|
10673
|
+
.context-button:disabled {
|
|
10674
|
+
opacity: 0.6;
|
|
10675
|
+
cursor: not-allowed;
|
|
10676
|
+
background-color: var(--jp-layout-color2);
|
|
10677
|
+
}
|
|
10678
|
+
|
|
10679
|
+
.context-button:disabled:hover {
|
|
10680
|
+
background-color: var(--jp-layout-color2);
|
|
10681
|
+
}`, "",{"version":3,"sources":["webpack://./style/ChatInput.css"],"names":[],"mappings":"AAAA;;;EAGE;;AAEF;EACE,gBAAgB;EAChB,SAAS;EACT,cAAc;EACd,gBAAgB;EAChB,2DAA2D;EAC3D;;;iCAG+B;EAC/B,WAAW;EACX,mBAAmB;EACnB,iDAAiD;AACnD;;AAEA;EACE,kBAAkB;EAClB,mBAAmB;AACrB;;AAEA;EACE,aAAa;EACb,YAAY;EACZ,YAAY;EACZ,WAAW;EACX,aAAa;EACb,kBAAkB;EAClB,sBAAsB;EACtB,yBAAyB;EACzB,2DAA2D;EAC3D,eAAe;EACf,gBAAgB;EAChB,qCAAqC;EACrC,gBAAgB;EAChB,iDAAiD;AACnD;;AAEA;EACE,aAAa;AACf;;AAEA;EACE,2BAA2B;EAC3B;;;iCAG+B;AACjC;;AAEA;EACE,+BAA+B;AACjC;;AAEA;EACE,+BAA+B;EAC/B,2BAA2B;AAC7B;;AAEA;EACE,+BAA+B;AACjC;;AAEA;EACE,aAAa;EACb,mBAAmB;EACnB,yCAAyC;EACzC,yCAAyC;EACzC,kBAAkB;EAClB,gBAAgB;EAChB,eAAe;EACf,yCAAyC;EACzC,eAAe;EACf,oCAAoC;EACpC,sCAAsC;AACxC;;AAEA;EACE,yCAAyC;AAC3C;;AAEA,0BAA0B;AAC1B;EACE,YAAY;EACZ,mBAAmB;EACnB,yCAAyC;AAC3C;;AAEA;EACE,YAAY;EACZ,mBAAmB;EACnB,yCAAyC;AAC3C;;AAEA;EACE,yCAAyC;AAC3C","sourcesContent":["/*\n * Copyright (c) Saga Inc.\n * Distributed under the terms of the GNU Affero General Public License v3.0 License.\n */\n\n.chat-input-container {\n position: sticky;\n bottom: 0;\n margin: 10px 0;\n margin-top: auto;\n background-color: var(--chat-user-message-background-color);\n box-shadow: \n 0 4px 12px rgba(0, 0, 0, 0.08),\n 0 2px 4px rgba(0, 0, 0, 0.06),\n 0 0 0 1px rgba(0, 0, 0, 0.02);\n width: 100%;\n border-radius: 12px;\n transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);\n}\n\n.chat-input-text-area-container {\n position: relative;\n height: min-content;\n}\n\n.chat-input {\n outline: none;\n border: none;\n resize: none;\n width: 100%;\n padding: 10px;\n overflow-y: hidden;\n box-sizing: border-box;\n flex-shrink: 0 !important;\n background-color: var(--chat-user-message-background-color);\n font-size: 12px;\n font-weight: 400;\n font-family: var(--jp-ui-font-family);\n line-height: 1.2;\n transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);\n}\n\n.active-cell-preview-container {\n padding: 10px;\n}\n\n.chat-input-container:focus-within {\n transform: translateY(-1px);\n box-shadow: \n 0 2px 8px rgba(0, 0, 0, 0.12),\n 0 8px 16px rgba(0, 0, 0, 0.08),\n 0 0 0 1px rgba(0, 0, 0, 0.04);\n}\n\n.chat-input:focus {\n color: var(--jp-ui-font-color1);\n}\n\n.chat-input::placeholder {\n color: var(--jp-ui-font-color2);\n transition: color 0.2s ease;\n}\n\n.chat-input:focus::placeholder {\n color: var(--jp-ui-font-color3);\n}\n\n.context-button {\n display: flex;\n align-items: center;\n background-color: var(--jp-layout-color2);\n border: 1px solid var(--jp-border-color1);\n border-radius: 3px;\n padding: 4px 8px;\n font-size: 12px;\n height: var(--chat-context-button-height);\n cursor: pointer;\n color: var(--jp-content-font-color1);\n transition: background-color 0.2s ease;\n}\n\n.context-button:hover {\n background-color: var(--jp-layout-color3);\n}\n\n/* Disabled state styles */\n.chat-input:disabled {\n opacity: 0.6;\n cursor: not-allowed;\n background-color: var(--jp-layout-color2);\n}\n\n.context-button:disabled {\n opacity: 0.6;\n cursor: not-allowed;\n background-color: var(--jp-layout-color2);\n}\n\n.context-button:disabled:hover {\n background-color: var(--jp-layout-color2);\n}"],"sourceRoot":""}]);
|
|
10385
10682
|
// Exports
|
|
10386
10683
|
/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (___CSS_LOADER_EXPORT___);
|
|
10387
10684
|
|
|
@@ -12532,6 +12829,128 @@ ___CSS_LOADER_EXPORT___.push([module.id, `/*
|
|
|
12532
12829
|
/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (___CSS_LOADER_EXPORT___);
|
|
12533
12830
|
|
|
12534
12831
|
|
|
12832
|
+
/***/ }),
|
|
12833
|
+
|
|
12834
|
+
/***/ "./node_modules/css-loader/dist/cjs.js!./style/RevertQuestionnaire.css":
|
|
12835
|
+
/*!*****************************************************************************!*\
|
|
12836
|
+
!*** ./node_modules/css-loader/dist/cjs.js!./style/RevertQuestionnaire.css ***!
|
|
12837
|
+
\*****************************************************************************/
|
|
12838
|
+
/***/ ((module, __webpack_exports__, __webpack_require__) => {
|
|
12839
|
+
|
|
12840
|
+
__webpack_require__.r(__webpack_exports__);
|
|
12841
|
+
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
12842
|
+
/* harmony export */ "default": () => (__WEBPACK_DEFAULT_EXPORT__)
|
|
12843
|
+
/* harmony export */ });
|
|
12844
|
+
/* harmony import */ var _node_modules_css_loader_dist_runtime_sourceMaps_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../node_modules/css-loader/dist/runtime/sourceMaps.js */ "./node_modules/css-loader/dist/runtime/sourceMaps.js");
|
|
12845
|
+
/* harmony import */ var _node_modules_css_loader_dist_runtime_sourceMaps_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_css_loader_dist_runtime_sourceMaps_js__WEBPACK_IMPORTED_MODULE_0__);
|
|
12846
|
+
/* harmony import */ var _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../node_modules/css-loader/dist/runtime/api.js */ "./node_modules/css-loader/dist/runtime/api.js");
|
|
12847
|
+
/* harmony import */ var _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1__);
|
|
12848
|
+
// Imports
|
|
12849
|
+
|
|
12850
|
+
|
|
12851
|
+
var ___CSS_LOADER_EXPORT___ = _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1___default()((_node_modules_css_loader_dist_runtime_sourceMaps_js__WEBPACK_IMPORTED_MODULE_0___default()));
|
|
12852
|
+
// Module
|
|
12853
|
+
___CSS_LOADER_EXPORT___.push([module.id, `/*
|
|
12854
|
+
* Copyright (c) Saga Inc.
|
|
12855
|
+
* Distributed under the terms of the GNU Affero General Public License v3.0 License.
|
|
12856
|
+
*/
|
|
12857
|
+
|
|
12858
|
+
.revert-questionnaire-message {
|
|
12859
|
+
display: flex;
|
|
12860
|
+
flex-direction: column;
|
|
12861
|
+
gap: 2px;
|
|
12862
|
+
padding: 12px 16px;
|
|
12863
|
+
margin: 8px 8px;
|
|
12864
|
+
border-radius: 12px;
|
|
12865
|
+
background-color: var(--chat-user-message-background-color);
|
|
12866
|
+
border: 1px solid var(--jp-border-color2);
|
|
12867
|
+
box-sizing: border-box;
|
|
12868
|
+
width: calc(100% - 16px);
|
|
12869
|
+
max-width: calc(100vw - 32px);
|
|
12870
|
+
}
|
|
12871
|
+
|
|
12872
|
+
.revert-questionnaire-message-text {
|
|
12873
|
+
font-size: 12px;
|
|
12874
|
+
color: var(--jp-ui-font-color1);
|
|
12875
|
+
margin-bottom: 20px;
|
|
12876
|
+
word-wrap: break-word;
|
|
12877
|
+
overflow-wrap: break-word;
|
|
12878
|
+
max-width: 100%;
|
|
12879
|
+
}
|
|
12880
|
+
|
|
12881
|
+
.revert-questionnaire-button {
|
|
12882
|
+
display: inline-flex;
|
|
12883
|
+
align-items: center;
|
|
12884
|
+
justify-content: space-between;
|
|
12885
|
+
gap: 8px;
|
|
12886
|
+
padding: 8px 12px;
|
|
12887
|
+
background: var(--jp-layout-color1);
|
|
12888
|
+
border: 1px solid var(--jp-border-color2);
|
|
12889
|
+
border-radius: 20px;
|
|
12890
|
+
color: var(--jp-ui-font-color2);
|
|
12891
|
+
font-size: 12px;
|
|
12892
|
+
cursor: pointer;
|
|
12893
|
+
transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
|
|
12894
|
+
text-align: left;
|
|
12895
|
+
width: 100%;
|
|
12896
|
+
overflow: hidden;
|
|
12897
|
+
position: relative;
|
|
12898
|
+
margin-bottom: 6px;
|
|
12899
|
+
box-sizing: border-box;
|
|
12900
|
+
word-wrap: break-word;
|
|
12901
|
+
overflow-wrap: break-word;
|
|
12902
|
+
white-space: normal;
|
|
12903
|
+
min-height: 36px;
|
|
12904
|
+
max-width: 100%;
|
|
12905
|
+
}
|
|
12906
|
+
|
|
12907
|
+
.revert-questionnaire-button::before {
|
|
12908
|
+
content: '';
|
|
12909
|
+
position: absolute;
|
|
12910
|
+
top: 0;
|
|
12911
|
+
left: 0;
|
|
12912
|
+
right: 0;
|
|
12913
|
+
bottom: 0;
|
|
12914
|
+
background: linear-gradient(135deg, var(--jp-brand-color3) 0%, rgba(var(--jp-brand-color1), 0.1) 100%);
|
|
12915
|
+
border-radius: 20px;
|
|
12916
|
+
opacity: 0;
|
|
12917
|
+
transition: opacity 0.2s ease;
|
|
12918
|
+
}
|
|
12919
|
+
|
|
12920
|
+
.revert-questionnaire-button:hover {
|
|
12921
|
+
background: var(--jp-layout-color2);
|
|
12922
|
+
transform: translateY(-1px) scale(1.02);
|
|
12923
|
+
box-shadow: 0 4px 12px rgba(var(--jp-brand-color1), 0.15);
|
|
12924
|
+
border-color: var(--jp-brand-color1);
|
|
12925
|
+
}
|
|
12926
|
+
|
|
12927
|
+
.revert-questionnaire-button:hover::before {
|
|
12928
|
+
opacity: 1;
|
|
12929
|
+
}
|
|
12930
|
+
|
|
12931
|
+
.revert-questionnaire-button:active {
|
|
12932
|
+
transform: translateY(0) scale(0.98);
|
|
12933
|
+
transition: all 0.1s ease;
|
|
12934
|
+
}
|
|
12935
|
+
|
|
12936
|
+
.revert-questionnaire-button::after {
|
|
12937
|
+
content: '→';
|
|
12938
|
+
color: var(--jp-brand-color1);
|
|
12939
|
+
transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
|
|
12940
|
+
opacity: 0;
|
|
12941
|
+
transform: translateX(-4px);
|
|
12942
|
+
flex-shrink: 0;
|
|
12943
|
+
margin-left: auto;
|
|
12944
|
+
}
|
|
12945
|
+
|
|
12946
|
+
.revert-questionnaire-button:hover::after {
|
|
12947
|
+
opacity: 1;
|
|
12948
|
+
transform: translateX(0);
|
|
12949
|
+
}`, "",{"version":3,"sources":["webpack://./style/RevertQuestionnaire.css"],"names":[],"mappings":"AAAA;;;EAGE;;AAEF;IACI,aAAa;IACb,sBAAsB;IACtB,QAAQ;IACR,kBAAkB;IAClB,eAAe;IACf,mBAAmB;IACnB,2DAA2D;IAC3D,yCAAyC;IACzC,sBAAsB;IACtB,wBAAwB;IACxB,6BAA6B;AACjC;;AAEA;IACI,eAAe;IACf,+BAA+B;IAC/B,mBAAmB;IACnB,qBAAqB;IACrB,yBAAyB;IACzB,eAAe;AACnB;;AAEA;IACI,oBAAoB;IACpB,mBAAmB;IACnB,8BAA8B;IAC9B,QAAQ;IACR,iBAAiB;IACjB,mCAAmC;IACnC,yCAAyC;IACzC,mBAAmB;IACnB,+BAA+B;IAC/B,eAAe;IACf,eAAe;IACf,iDAAiD;IACjD,gBAAgB;IAChB,WAAW;IACX,gBAAgB;IAChB,kBAAkB;IAClB,kBAAkB;IAClB,sBAAsB;IACtB,qBAAqB;IACrB,yBAAyB;IACzB,mBAAmB;IACnB,gBAAgB;IAChB,eAAe;AACnB;;AAEA;IACI,WAAW;IACX,kBAAkB;IAClB,MAAM;IACN,OAAO;IACP,QAAQ;IACR,SAAS;IACT,sGAAsG;IACtG,mBAAmB;IACnB,UAAU;IACV,6BAA6B;AACjC;;AAEA;IACI,mCAAmC;IACnC,uCAAuC;IACvC,yDAAyD;IACzD,oCAAoC;AACxC;;AAEA;IACI,UAAU;AACd;;AAEA;IACI,oCAAoC;IACpC,yBAAyB;AAC7B;;AAEA;IACI,YAAY;IACZ,6BAA6B;IAC7B,iDAAiD;IACjD,UAAU;IACV,2BAA2B;IAC3B,cAAc;IACd,iBAAiB;AACrB;;AAEA;IACI,UAAU;IACV,wBAAwB;AAC5B","sourcesContent":["/*\n * Copyright (c) Saga Inc.\n * Distributed under the terms of the GNU Affero General Public License v3.0 License.\n */\n\n.revert-questionnaire-message {\n display: flex;\n flex-direction: column;\n gap: 2px;\n padding: 12px 16px;\n margin: 8px 8px;\n border-radius: 12px;\n background-color: var(--chat-user-message-background-color);\n border: 1px solid var(--jp-border-color2);\n box-sizing: border-box;\n width: calc(100% - 16px);\n max-width: calc(100vw - 32px);\n}\n\n.revert-questionnaire-message-text {\n font-size: 12px;\n color: var(--jp-ui-font-color1);\n margin-bottom: 20px;\n word-wrap: break-word;\n overflow-wrap: break-word;\n max-width: 100%;\n}\n\n.revert-questionnaire-button {\n display: inline-flex;\n align-items: center;\n justify-content: space-between;\n gap: 8px;\n padding: 8px 12px;\n background: var(--jp-layout-color1);\n border: 1px solid var(--jp-border-color2);\n border-radius: 20px;\n color: var(--jp-ui-font-color2);\n font-size: 12px;\n cursor: pointer;\n transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);\n text-align: left;\n width: 100%;\n overflow: hidden;\n position: relative;\n margin-bottom: 6px;\n box-sizing: border-box;\n word-wrap: break-word;\n overflow-wrap: break-word;\n white-space: normal;\n min-height: 36px;\n max-width: 100%;\n}\n\n.revert-questionnaire-button::before {\n content: '';\n position: absolute;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n background: linear-gradient(135deg, var(--jp-brand-color3) 0%, rgba(var(--jp-brand-color1), 0.1) 100%);\n border-radius: 20px;\n opacity: 0;\n transition: opacity 0.2s ease;\n}\n\n.revert-questionnaire-button:hover {\n background: var(--jp-layout-color2);\n transform: translateY(-1px) scale(1.02);\n box-shadow: 0 4px 12px rgba(var(--jp-brand-color1), 0.15);\n border-color: var(--jp-brand-color1);\n}\n\n.revert-questionnaire-button:hover::before {\n opacity: 1;\n}\n\n.revert-questionnaire-button:active {\n transform: translateY(0) scale(0.98);\n transition: all 0.1s ease;\n}\n\n.revert-questionnaire-button::after {\n content: '→';\n color: var(--jp-brand-color1);\n transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);\n opacity: 0;\n transform: translateX(-4px);\n flex-shrink: 0;\n margin-left: auto;\n}\n\n.revert-questionnaire-button:hover::after {\n opacity: 1;\n transform: translateX(0);\n}"],"sourceRoot":""}]);
|
|
12950
|
+
// Exports
|
|
12951
|
+
/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (___CSS_LOADER_EXPORT___);
|
|
12952
|
+
|
|
12953
|
+
|
|
12535
12954
|
/***/ }),
|
|
12536
12955
|
|
|
12537
12956
|
/***/ "./node_modules/css-loader/dist/cjs.js!./style/RulesForm.css":
|
|
@@ -12929,7 +13348,19 @@ ___CSS_LOADER_EXPORT___.push([module.id, `/*
|
|
|
12929
13348
|
align-items: center;
|
|
12930
13349
|
justify-content: space-around;
|
|
12931
13350
|
}
|
|
12932
|
-
|
|
13351
|
+
|
|
13352
|
+
.text-align-left {
|
|
13353
|
+
justify-content: flex-start;
|
|
13354
|
+
}
|
|
13355
|
+
|
|
13356
|
+
.text-align-center {
|
|
13357
|
+
justify-content: space-around;
|
|
13358
|
+
}
|
|
13359
|
+
|
|
13360
|
+
.text-align-right {
|
|
13361
|
+
justify-content: flex-end;
|
|
13362
|
+
}
|
|
13363
|
+
`, "",{"version":3,"sources":["webpack://./style/TextButton.css"],"names":[],"mappings":"AAAA;;;EAGE;;AAEF;EACE,aAAa;EACb,mBAAmB;EACnB,6BAA6B;AAC/B;;AAEA;EACE,2BAA2B;AAC7B;;AAEA;EACE,6BAA6B;AAC/B;;AAEA;EACE,yBAAyB;AAC3B","sourcesContent":["/*\n * Copyright (c) Saga Inc.\n * Distributed under the terms of the GNU Affero General Public License v3.0 License.\n */\n\n.text-button-mito-ai {\n display: flex;\n align-items: center;\n justify-content: space-around;\n}\n\n.text-align-left {\n justify-content: flex-start;\n}\n\n.text-align-center {\n justify-content: space-around;\n}\n\n.text-align-right {\n justify-content: flex-end;\n}\n"],"sourceRoot":""}]);
|
|
12933
13364
|
// Exports
|
|
12934
13365
|
/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (___CSS_LOADER_EXPORT___);
|
|
12935
13366
|
|
|
@@ -13100,7 +13531,8 @@ ___CSS_LOADER_EXPORT___.push([module.id, `/*
|
|
|
13100
13531
|
height: 20px;
|
|
13101
13532
|
font-size: 12px;
|
|
13102
13533
|
padding: 2px 5px;
|
|
13103
|
-
}
|
|
13534
|
+
}
|
|
13535
|
+
`, "",{"version":3,"sources":["webpack://./style/button.css"],"names":[],"mappings":"AAAA;;;EAGE;;AAEF;;;;CAIC;;AAED;EACE,YAAY;EACZ,kBAAkB;EAClB,eAAe;EACf,eAAe;EACf,2EAA2E;EAC3E,mBAAmB;EACnB,iBAAiB;AACnB;;AAEA;EACE,kCAAkC;EAClC,kCAAkC;AACpC;;AAEA;EACE,kCAAkC;AACpC;;AAEA;EACE,gCAAgC;EAChC,gCAAgC;AAClC;;AAEA;EACE,gCAAgC;AAClC;;AAEA;EACE,yCAAyC;EACzC,+CAA+C;AACjD;;AAEA;EACE,yCAAyC;AAC3C;;AAEA;EACE,mCAAmC;EACnC,mCAAmC;AACrC;;AAEA;EACE,mCAAmC;AACrC;;AAEA;EACE,WAAW;AACb;;AAEA;EACE,kBAAkB;AACpB;;AAEA;EACE,YAAY;EACZ,eAAe;EACf,gBAAgB;AAClB","sourcesContent":["/*\n * Copyright (c) Saga Inc.\n * Distributed under the terms of the GNU Affero General Public License v3.0 License.\n */\n\n/* \n Classes that can be used for any button, making it easier to keep \n the theme consistent. For example, use them to make a textButton or\n textAndIconButton green.\n*/\n\n.button-base {\n border: none;\n border-radius: 3px;\n cursor: pointer;\n font-size: 14px;\n /* Make sure the button grows large enough so that the text does not wrap */\n white-space: nowrap;\n padding: 5px 10px;\n}\n\n.button-green {\n background-color: var(--green-400);\n color: var(--green-900) !important;\n}\n\n.button-green:hover {\n background-color: var(--green-500);\n}\n\n.button-red {\n background-color: var(--red-400);\n color: var(--red-900) !important;\n}\n\n.button-red:hover {\n background-color: var(--red-500);\n}\n\n.button-gray {\n background-color: var(--jp-layout-color2);\n color: var(--jp-content-font-color1) !important;\n}\n\n.button-gray:hover {\n background-color: var(--jp-layout-color3);\n}\n\n.button-purple {\n background-color: var(--purple-300);\n color: var(--purple-700) !important;\n}\n\n.button-purple:hover {\n background-color: var(--purple-400);\n}\n\n.button-width-block {\n width: 100%;\n}\n\n.button-width-fit-contents {\n width: fit-content;\n}\n\n.button-small {\n height: 20px;\n font-size: 12px;\n padding: 2px 5px;\n}\n"],"sourceRoot":""}]);
|
|
13104
13536
|
// Exports
|
|
13105
13537
|
/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (___CSS_LOADER_EXPORT___);
|
|
13106
13538
|
|
|
@@ -14717,6 +15149,60 @@ var update = _node_modules_style_loader_dist_runtime_injectStylesIntoStyleTag_js
|
|
|
14717
15149
|
/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (_node_modules_css_loader_dist_cjs_js_PythonCode_css__WEBPACK_IMPORTED_MODULE_6__["default"] && _node_modules_css_loader_dist_cjs_js_PythonCode_css__WEBPACK_IMPORTED_MODULE_6__["default"].locals ? _node_modules_css_loader_dist_cjs_js_PythonCode_css__WEBPACK_IMPORTED_MODULE_6__["default"].locals : undefined);
|
|
14718
15150
|
|
|
14719
15151
|
|
|
15152
|
+
/***/ }),
|
|
15153
|
+
|
|
15154
|
+
/***/ "./style/RevertQuestionnaire.css":
|
|
15155
|
+
/*!***************************************!*\
|
|
15156
|
+
!*** ./style/RevertQuestionnaire.css ***!
|
|
15157
|
+
\***************************************/
|
|
15158
|
+
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
15159
|
+
|
|
15160
|
+
__webpack_require__.r(__webpack_exports__);
|
|
15161
|
+
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
15162
|
+
/* harmony export */ "default": () => (__WEBPACK_DEFAULT_EXPORT__)
|
|
15163
|
+
/* harmony export */ });
|
|
15164
|
+
/* harmony import */ var _node_modules_style_loader_dist_runtime_injectStylesIntoStyleTag_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! !../node_modules/style-loader/dist/runtime/injectStylesIntoStyleTag.js */ "./node_modules/style-loader/dist/runtime/injectStylesIntoStyleTag.js");
|
|
15165
|
+
/* harmony import */ var _node_modules_style_loader_dist_runtime_injectStylesIntoStyleTag_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_style_loader_dist_runtime_injectStylesIntoStyleTag_js__WEBPACK_IMPORTED_MODULE_0__);
|
|
15166
|
+
/* harmony import */ var _node_modules_style_loader_dist_runtime_styleDomAPI_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! !../node_modules/style-loader/dist/runtime/styleDomAPI.js */ "./node_modules/style-loader/dist/runtime/styleDomAPI.js");
|
|
15167
|
+
/* harmony import */ var _node_modules_style_loader_dist_runtime_styleDomAPI_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_node_modules_style_loader_dist_runtime_styleDomAPI_js__WEBPACK_IMPORTED_MODULE_1__);
|
|
15168
|
+
/* harmony import */ var _node_modules_style_loader_dist_runtime_insertBySelector_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! !../node_modules/style-loader/dist/runtime/insertBySelector.js */ "./node_modules/style-loader/dist/runtime/insertBySelector.js");
|
|
15169
|
+
/* harmony import */ var _node_modules_style_loader_dist_runtime_insertBySelector_js__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_node_modules_style_loader_dist_runtime_insertBySelector_js__WEBPACK_IMPORTED_MODULE_2__);
|
|
15170
|
+
/* harmony import */ var _node_modules_style_loader_dist_runtime_setAttributesWithoutAttributes_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! !../node_modules/style-loader/dist/runtime/setAttributesWithoutAttributes.js */ "./node_modules/style-loader/dist/runtime/setAttributesWithoutAttributes.js");
|
|
15171
|
+
/* harmony import */ var _node_modules_style_loader_dist_runtime_setAttributesWithoutAttributes_js__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_node_modules_style_loader_dist_runtime_setAttributesWithoutAttributes_js__WEBPACK_IMPORTED_MODULE_3__);
|
|
15172
|
+
/* harmony import */ var _node_modules_style_loader_dist_runtime_insertStyleElement_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! !../node_modules/style-loader/dist/runtime/insertStyleElement.js */ "./node_modules/style-loader/dist/runtime/insertStyleElement.js");
|
|
15173
|
+
/* harmony import */ var _node_modules_style_loader_dist_runtime_insertStyleElement_js__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_node_modules_style_loader_dist_runtime_insertStyleElement_js__WEBPACK_IMPORTED_MODULE_4__);
|
|
15174
|
+
/* harmony import */ var _node_modules_style_loader_dist_runtime_styleTagTransform_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! !../node_modules/style-loader/dist/runtime/styleTagTransform.js */ "./node_modules/style-loader/dist/runtime/styleTagTransform.js");
|
|
15175
|
+
/* harmony import */ var _node_modules_style_loader_dist_runtime_styleTagTransform_js__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(_node_modules_style_loader_dist_runtime_styleTagTransform_js__WEBPACK_IMPORTED_MODULE_5__);
|
|
15176
|
+
/* harmony import */ var _node_modules_css_loader_dist_cjs_js_RevertQuestionnaire_css__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! !!../node_modules/css-loader/dist/cjs.js!./RevertQuestionnaire.css */ "./node_modules/css-loader/dist/cjs.js!./style/RevertQuestionnaire.css");
|
|
15177
|
+
|
|
15178
|
+
|
|
15179
|
+
|
|
15180
|
+
|
|
15181
|
+
|
|
15182
|
+
|
|
15183
|
+
|
|
15184
|
+
|
|
15185
|
+
|
|
15186
|
+
|
|
15187
|
+
|
|
15188
|
+
var options = {};
|
|
15189
|
+
|
|
15190
|
+
options.styleTagTransform = (_node_modules_style_loader_dist_runtime_styleTagTransform_js__WEBPACK_IMPORTED_MODULE_5___default());
|
|
15191
|
+
options.setAttributes = (_node_modules_style_loader_dist_runtime_setAttributesWithoutAttributes_js__WEBPACK_IMPORTED_MODULE_3___default());
|
|
15192
|
+
|
|
15193
|
+
options.insert = _node_modules_style_loader_dist_runtime_insertBySelector_js__WEBPACK_IMPORTED_MODULE_2___default().bind(null, "head");
|
|
15194
|
+
|
|
15195
|
+
options.domAPI = (_node_modules_style_loader_dist_runtime_styleDomAPI_js__WEBPACK_IMPORTED_MODULE_1___default());
|
|
15196
|
+
options.insertStyleElement = (_node_modules_style_loader_dist_runtime_insertStyleElement_js__WEBPACK_IMPORTED_MODULE_4___default());
|
|
15197
|
+
|
|
15198
|
+
var update = _node_modules_style_loader_dist_runtime_injectStylesIntoStyleTag_js__WEBPACK_IMPORTED_MODULE_0___default()(_node_modules_css_loader_dist_cjs_js_RevertQuestionnaire_css__WEBPACK_IMPORTED_MODULE_6__["default"], options);
|
|
15199
|
+
|
|
15200
|
+
|
|
15201
|
+
|
|
15202
|
+
|
|
15203
|
+
/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (_node_modules_css_loader_dist_cjs_js_RevertQuestionnaire_css__WEBPACK_IMPORTED_MODULE_6__["default"] && _node_modules_css_loader_dist_cjs_js_RevertQuestionnaire_css__WEBPACK_IMPORTED_MODULE_6__["default"].locals ? _node_modules_css_loader_dist_cjs_js_RevertQuestionnaire_css__WEBPACK_IMPORTED_MODULE_6__["default"].locals : undefined);
|
|
15204
|
+
|
|
15205
|
+
|
|
14720
15206
|
/***/ }),
|
|
14721
15207
|
|
|
14722
15208
|
/***/ "./style/RulesForm.css":
|
|
@@ -15098,4 +15584,4 @@ var update = _node_modules_style_loader_dist_runtime_injectStylesIntoStyleTag_js
|
|
|
15098
15584
|
/***/ })
|
|
15099
15585
|
|
|
15100
15586
|
}]);
|
|
15101
|
-
//# sourceMappingURL=lib_index_js.
|
|
15587
|
+
//# sourceMappingURL=lib_index_js.5d1d7c234e2dc7c9d97b.js.map
|