@mastra/playground-ui 5.1.10-alpha.1 → 5.1.11-alpha.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.es.js
CHANGED
|
@@ -5219,13 +5219,20 @@ function useAgentModelSettingsState({ agentId }) {
|
|
|
5219
5219
|
console.error(e);
|
|
5220
5220
|
}
|
|
5221
5221
|
}, [LOCAL_STORAGE_KEY]);
|
|
5222
|
-
|
|
5223
|
-
|
|
5224
|
-
|
|
5225
|
-
|
|
5226
|
-
|
|
5227
|
-
|
|
5228
|
-
|
|
5222
|
+
const setModelSettings = (modelSettingsValue) => {
|
|
5223
|
+
setModelSettingsState((prev) => ({ ...prev, ...modelSettingsValue }));
|
|
5224
|
+
localStorage.setItem(
|
|
5225
|
+
LOCAL_STORAGE_KEY,
|
|
5226
|
+
JSON.stringify({ modelSettings: modelSettingsValue, chatWithGenerate, agentId })
|
|
5227
|
+
);
|
|
5228
|
+
};
|
|
5229
|
+
const setChatWithGenerate = (chatWithGenerateValue) => {
|
|
5230
|
+
setChatWithGenerateState(chatWithGenerateValue);
|
|
5231
|
+
localStorage.setItem(
|
|
5232
|
+
LOCAL_STORAGE_KEY,
|
|
5233
|
+
JSON.stringify({ modelSettings, chatWithGenerate: chatWithGenerateValue, agentId })
|
|
5234
|
+
);
|
|
5235
|
+
};
|
|
5229
5236
|
const resetAll = () => {
|
|
5230
5237
|
setModelSettingsState(defaultModelSettings$1);
|
|
5231
5238
|
setChatWithGenerate(false);
|