@sqaitech/visualizer 0.30.12 → 0.30.13
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/es/store/history.mjs +16 -2
- package/dist/es/store/store.mjs +38 -9
- package/dist/lib/store/history.js +16 -2
- package/dist/lib/store/store.js +38 -9
- package/package.json +5 -5
|
@@ -27,8 +27,22 @@ __webpack_require__.d(external_zustand_namespaceObject, {
|
|
|
27
27
|
create: ()=>create
|
|
28
28
|
});
|
|
29
29
|
const { create: history_create } = external_zustand_namespaceObject;
|
|
30
|
-
const HISTORY_KEY = '
|
|
31
|
-
const LAST_SELECTED_TYPE_KEY = '
|
|
30
|
+
const HISTORY_KEY = 'sqai-prompt-history-v2';
|
|
31
|
+
const LAST_SELECTED_TYPE_KEY = 'sqai-last-selected-type';
|
|
32
|
+
const OLD_HISTORY_KEY = 'midscene-prompt-history-v2';
|
|
33
|
+
const OLD_LAST_SELECTED_TYPE_KEY = 'midscene-last-selected-type';
|
|
34
|
+
const migrateLocalStorageKey = (oldKey, newKey)=>{
|
|
35
|
+
if ('undefined' == typeof window || 'undefined' == typeof localStorage) return;
|
|
36
|
+
const oldValue = localStorage.getItem(oldKey);
|
|
37
|
+
if (null !== oldValue && null === localStorage.getItem(newKey)) {
|
|
38
|
+
localStorage.setItem(newKey, oldValue);
|
|
39
|
+
localStorage.removeItem(oldKey);
|
|
40
|
+
}
|
|
41
|
+
};
|
|
42
|
+
if ('undefined' != typeof window && 'undefined' != typeof localStorage) {
|
|
43
|
+
migrateLocalStorageKey(OLD_HISTORY_KEY, HISTORY_KEY);
|
|
44
|
+
migrateLocalStorageKey(OLD_LAST_SELECTED_TYPE_KEY, LAST_SELECTED_TYPE_KEY);
|
|
45
|
+
}
|
|
32
46
|
const getHistoryFromLocalStorage = ()=>{
|
|
33
47
|
const historyString = localStorage.getItem(HISTORY_KEY);
|
|
34
48
|
return historyString ? JSON.parse(historyString) : {};
|
package/dist/es/store/store.mjs
CHANGED
|
@@ -27,9 +27,24 @@ __webpack_require__.d(external_zustand_namespaceObject, {
|
|
|
27
27
|
create: ()=>create
|
|
28
28
|
});
|
|
29
29
|
const { create: store_create } = external_zustand_namespaceObject;
|
|
30
|
-
const AUTO_ZOOM_KEY = '
|
|
31
|
-
const BACKGROUND_VISIBLE_KEY = '
|
|
32
|
-
const ELEMENTS_VISIBLE_KEY = '
|
|
30
|
+
const AUTO_ZOOM_KEY = 'sqai-auto-zoom';
|
|
31
|
+
const BACKGROUND_VISIBLE_KEY = 'sqai-background-visible';
|
|
32
|
+
const ELEMENTS_VISIBLE_KEY = 'sqai-elements-visible';
|
|
33
|
+
const OLD_AUTO_ZOOM_KEY = 'midscene-auto-zoom';
|
|
34
|
+
const OLD_BACKGROUND_VISIBLE_KEY = 'midscene-background-visible';
|
|
35
|
+
const OLD_ELEMENTS_VISIBLE_KEY = 'midscene-elements-visible';
|
|
36
|
+
const migrateLocalStorageKey = (oldKey, newKey)=>{
|
|
37
|
+
const oldValue = localStorage.getItem(oldKey);
|
|
38
|
+
if (null !== oldValue && null === localStorage.getItem(newKey)) {
|
|
39
|
+
localStorage.setItem(newKey, oldValue);
|
|
40
|
+
localStorage.removeItem(oldKey);
|
|
41
|
+
}
|
|
42
|
+
};
|
|
43
|
+
if ('undefined' != typeof window && 'undefined' != typeof localStorage) {
|
|
44
|
+
migrateLocalStorageKey(OLD_AUTO_ZOOM_KEY, AUTO_ZOOM_KEY);
|
|
45
|
+
migrateLocalStorageKey(OLD_BACKGROUND_VISIBLE_KEY, BACKGROUND_VISIBLE_KEY);
|
|
46
|
+
migrateLocalStorageKey(OLD_ELEMENTS_VISIBLE_KEY, ELEMENTS_VISIBLE_KEY);
|
|
47
|
+
}
|
|
33
48
|
const parseBooleanParam = (value)=>{
|
|
34
49
|
if (null === value) return;
|
|
35
50
|
const normalized = value.trim().toLowerCase();
|
|
@@ -81,12 +96,26 @@ const useBlackboardPreference = store_create((set)=>{
|
|
|
81
96
|
}
|
|
82
97
|
};
|
|
83
98
|
});
|
|
84
|
-
const CONFIG_KEY = '
|
|
85
|
-
const SERVICE_MODE_KEY = '
|
|
86
|
-
const TRACKING_ACTIVE_TAB_KEY = '
|
|
87
|
-
const DEEP_THINK_KEY = '
|
|
88
|
-
const SCREENSHOT_INCLUDED_KEY = '
|
|
89
|
-
const DOM_INCLUDED_KEY = '
|
|
99
|
+
const CONFIG_KEY = 'sqai-env-config';
|
|
100
|
+
const SERVICE_MODE_KEY = 'sqai-service-mode';
|
|
101
|
+
const TRACKING_ACTIVE_TAB_KEY = 'sqai-tracking-active-tab';
|
|
102
|
+
const DEEP_THINK_KEY = 'sqai-deep-think';
|
|
103
|
+
const SCREENSHOT_INCLUDED_KEY = 'sqai-screenshot-included';
|
|
104
|
+
const DOM_INCLUDED_KEY = 'sqai-dom-included';
|
|
105
|
+
const OLD_CONFIG_KEY = 'midscene-env-config';
|
|
106
|
+
const OLD_SERVICE_MODE_KEY = 'midscene-service-mode';
|
|
107
|
+
const OLD_TRACKING_ACTIVE_TAB_KEY = 'midscene-tracking-active-tab';
|
|
108
|
+
const OLD_DEEP_THINK_KEY = 'midscene-deep-think';
|
|
109
|
+
const OLD_SCREENSHOT_INCLUDED_KEY = 'midscene-screenshot-included';
|
|
110
|
+
const OLD_DOM_INCLUDED_KEY = 'midscene-dom-included';
|
|
111
|
+
if ('undefined' != typeof window && 'undefined' != typeof localStorage) {
|
|
112
|
+
migrateLocalStorageKey(OLD_CONFIG_KEY, CONFIG_KEY);
|
|
113
|
+
migrateLocalStorageKey(OLD_SERVICE_MODE_KEY, SERVICE_MODE_KEY);
|
|
114
|
+
migrateLocalStorageKey(OLD_TRACKING_ACTIVE_TAB_KEY, TRACKING_ACTIVE_TAB_KEY);
|
|
115
|
+
migrateLocalStorageKey(OLD_DEEP_THINK_KEY, DEEP_THINK_KEY);
|
|
116
|
+
migrateLocalStorageKey(OLD_SCREENSHOT_INCLUDED_KEY, SCREENSHOT_INCLUDED_KEY);
|
|
117
|
+
migrateLocalStorageKey(OLD_DOM_INCLUDED_KEY, DOM_INCLUDED_KEY);
|
|
118
|
+
}
|
|
90
119
|
const getConfigStringFromLocalStorage = ()=>{
|
|
91
120
|
const configString = localStorage.getItem(CONFIG_KEY);
|
|
92
121
|
return configString || '';
|
|
@@ -28,8 +28,22 @@ __webpack_require__.d(__webpack_exports__, {
|
|
|
28
28
|
});
|
|
29
29
|
const external_zustand_namespaceObject = require("zustand");
|
|
30
30
|
const { create } = external_zustand_namespaceObject;
|
|
31
|
-
const HISTORY_KEY = '
|
|
32
|
-
const LAST_SELECTED_TYPE_KEY = '
|
|
31
|
+
const HISTORY_KEY = 'sqai-prompt-history-v2';
|
|
32
|
+
const LAST_SELECTED_TYPE_KEY = 'sqai-last-selected-type';
|
|
33
|
+
const OLD_HISTORY_KEY = 'midscene-prompt-history-v2';
|
|
34
|
+
const OLD_LAST_SELECTED_TYPE_KEY = 'midscene-last-selected-type';
|
|
35
|
+
const migrateLocalStorageKey = (oldKey, newKey)=>{
|
|
36
|
+
if ('undefined' == typeof window || 'undefined' == typeof localStorage) return;
|
|
37
|
+
const oldValue = localStorage.getItem(oldKey);
|
|
38
|
+
if (null !== oldValue && null === localStorage.getItem(newKey)) {
|
|
39
|
+
localStorage.setItem(newKey, oldValue);
|
|
40
|
+
localStorage.removeItem(oldKey);
|
|
41
|
+
}
|
|
42
|
+
};
|
|
43
|
+
if ('undefined' != typeof window && 'undefined' != typeof localStorage) {
|
|
44
|
+
migrateLocalStorageKey(OLD_HISTORY_KEY, HISTORY_KEY);
|
|
45
|
+
migrateLocalStorageKey(OLD_LAST_SELECTED_TYPE_KEY, LAST_SELECTED_TYPE_KEY);
|
|
46
|
+
}
|
|
33
47
|
const getHistoryFromLocalStorage = ()=>{
|
|
34
48
|
const historyString = localStorage.getItem(HISTORY_KEY);
|
|
35
49
|
return historyString ? JSON.parse(historyString) : {};
|
package/dist/lib/store/store.js
CHANGED
|
@@ -29,9 +29,24 @@ __webpack_require__.d(__webpack_exports__, {
|
|
|
29
29
|
});
|
|
30
30
|
const external_zustand_namespaceObject = require("zustand");
|
|
31
31
|
const { create } = external_zustand_namespaceObject;
|
|
32
|
-
const AUTO_ZOOM_KEY = '
|
|
33
|
-
const BACKGROUND_VISIBLE_KEY = '
|
|
34
|
-
const ELEMENTS_VISIBLE_KEY = '
|
|
32
|
+
const AUTO_ZOOM_KEY = 'sqai-auto-zoom';
|
|
33
|
+
const BACKGROUND_VISIBLE_KEY = 'sqai-background-visible';
|
|
34
|
+
const ELEMENTS_VISIBLE_KEY = 'sqai-elements-visible';
|
|
35
|
+
const OLD_AUTO_ZOOM_KEY = 'midscene-auto-zoom';
|
|
36
|
+
const OLD_BACKGROUND_VISIBLE_KEY = 'midscene-background-visible';
|
|
37
|
+
const OLD_ELEMENTS_VISIBLE_KEY = 'midscene-elements-visible';
|
|
38
|
+
const migrateLocalStorageKey = (oldKey, newKey)=>{
|
|
39
|
+
const oldValue = localStorage.getItem(oldKey);
|
|
40
|
+
if (null !== oldValue && null === localStorage.getItem(newKey)) {
|
|
41
|
+
localStorage.setItem(newKey, oldValue);
|
|
42
|
+
localStorage.removeItem(oldKey);
|
|
43
|
+
}
|
|
44
|
+
};
|
|
45
|
+
if ('undefined' != typeof window && 'undefined' != typeof localStorage) {
|
|
46
|
+
migrateLocalStorageKey(OLD_AUTO_ZOOM_KEY, AUTO_ZOOM_KEY);
|
|
47
|
+
migrateLocalStorageKey(OLD_BACKGROUND_VISIBLE_KEY, BACKGROUND_VISIBLE_KEY);
|
|
48
|
+
migrateLocalStorageKey(OLD_ELEMENTS_VISIBLE_KEY, ELEMENTS_VISIBLE_KEY);
|
|
49
|
+
}
|
|
35
50
|
const parseBooleanParam = (value)=>{
|
|
36
51
|
if (null === value) return;
|
|
37
52
|
const normalized = value.trim().toLowerCase();
|
|
@@ -83,12 +98,26 @@ const useBlackboardPreference = create((set)=>{
|
|
|
83
98
|
}
|
|
84
99
|
};
|
|
85
100
|
});
|
|
86
|
-
const CONFIG_KEY = '
|
|
87
|
-
const SERVICE_MODE_KEY = '
|
|
88
|
-
const TRACKING_ACTIVE_TAB_KEY = '
|
|
89
|
-
const DEEP_THINK_KEY = '
|
|
90
|
-
const SCREENSHOT_INCLUDED_KEY = '
|
|
91
|
-
const DOM_INCLUDED_KEY = '
|
|
101
|
+
const CONFIG_KEY = 'sqai-env-config';
|
|
102
|
+
const SERVICE_MODE_KEY = 'sqai-service-mode';
|
|
103
|
+
const TRACKING_ACTIVE_TAB_KEY = 'sqai-tracking-active-tab';
|
|
104
|
+
const DEEP_THINK_KEY = 'sqai-deep-think';
|
|
105
|
+
const SCREENSHOT_INCLUDED_KEY = 'sqai-screenshot-included';
|
|
106
|
+
const DOM_INCLUDED_KEY = 'sqai-dom-included';
|
|
107
|
+
const OLD_CONFIG_KEY = 'midscene-env-config';
|
|
108
|
+
const OLD_SERVICE_MODE_KEY = 'midscene-service-mode';
|
|
109
|
+
const OLD_TRACKING_ACTIVE_TAB_KEY = 'midscene-tracking-active-tab';
|
|
110
|
+
const OLD_DEEP_THINK_KEY = 'midscene-deep-think';
|
|
111
|
+
const OLD_SCREENSHOT_INCLUDED_KEY = 'midscene-screenshot-included';
|
|
112
|
+
const OLD_DOM_INCLUDED_KEY = 'midscene-dom-included';
|
|
113
|
+
if ('undefined' != typeof window && 'undefined' != typeof localStorage) {
|
|
114
|
+
migrateLocalStorageKey(OLD_CONFIG_KEY, CONFIG_KEY);
|
|
115
|
+
migrateLocalStorageKey(OLD_SERVICE_MODE_KEY, SERVICE_MODE_KEY);
|
|
116
|
+
migrateLocalStorageKey(OLD_TRACKING_ACTIVE_TAB_KEY, TRACKING_ACTIVE_TAB_KEY);
|
|
117
|
+
migrateLocalStorageKey(OLD_DEEP_THINK_KEY, DEEP_THINK_KEY);
|
|
118
|
+
migrateLocalStorageKey(OLD_SCREENSHOT_INCLUDED_KEY, SCREENSHOT_INCLUDED_KEY);
|
|
119
|
+
migrateLocalStorageKey(OLD_DOM_INCLUDED_KEY, DOM_INCLUDED_KEY);
|
|
120
|
+
}
|
|
92
121
|
const getConfigStringFromLocalStorage = ()=>{
|
|
93
122
|
const configString = localStorage.getItem(CONFIG_KEY);
|
|
94
123
|
return configString || '';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sqaitech/visualizer",
|
|
3
|
-
"version": "0.30.
|
|
3
|
+
"version": "0.30.13",
|
|
4
4
|
"repository": "https://github.com/qa-nparekh/midscene",
|
|
5
5
|
"homepage": "https://sqai.tech/",
|
|
6
6
|
"types": "./dist/types/index.d.ts",
|
|
@@ -70,10 +70,10 @@
|
|
|
70
70
|
"antd": "^5.21.6",
|
|
71
71
|
"buffer": "6.0.3",
|
|
72
72
|
"dayjs": "^1.11.11",
|
|
73
|
-
"@sqaitech/core": "0.30.
|
|
74
|
-
"@sqaitech/playground": "0.30.
|
|
75
|
-
"@sqaitech/
|
|
76
|
-
"@sqaitech/
|
|
73
|
+
"@sqaitech/core": "0.30.13",
|
|
74
|
+
"@sqaitech/playground": "0.30.13",
|
|
75
|
+
"@sqaitech/shared": "0.30.13",
|
|
76
|
+
"@sqaitech/web": "0.30.13"
|
|
77
77
|
},
|
|
78
78
|
"license": "MIT",
|
|
79
79
|
"scripts": {
|