@buoy-gg/core 1.7.5 → 1.7.8
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/lib/commonjs/floatingMenu/AppHost.js +1 -1
- package/lib/commonjs/floatingMenu/DevToolsSettingsModal.js +20 -8
- package/lib/commonjs/floatingMenu/DevToolsSettingsModal.web.js +746 -0
- package/lib/commonjs/floatingMenu/FloatingDevTools.js +16 -4
- package/lib/commonjs/floatingMenu/FloatingDevTools.web.js +154 -0
- package/lib/commonjs/floatingMenu/FloatingMenu.js +8 -8
- package/lib/commonjs/floatingMenu/autoDiscoverPresets.js +15 -0
- package/lib/commonjs/floatingMenu/defaultConfig.js +14 -7
- package/lib/commonjs/floatingMenu/dial/DialDevTools.js +8 -2
- package/lib/commonjs/floatingMenu/dial/DialDevTools.web.js +593 -0
- package/lib/commonjs/floatingMenu/dial/OnboardingTooltip.js +2 -2
- package/lib/commonjs/floatingMenu/floatingTools.web.js +357 -0
- package/lib/commonjs/index.js +2 -2
- package/lib/commonjs/index.web.js +131 -0
- package/lib/commonjs/utils/autoDiscoverPresets.web.js +181 -0
- package/lib/module/floatingMenu/AppHost.js +1 -1
- package/lib/module/floatingMenu/DevToolsSettingsModal.js +21 -9
- package/lib/module/floatingMenu/DevToolsSettingsModal.web.js +756 -0
- package/lib/module/floatingMenu/FloatingDevTools.js +17 -5
- package/lib/module/floatingMenu/FloatingDevTools.web.js +150 -0
- package/lib/module/floatingMenu/FloatingMenu.js +8 -8
- package/lib/module/floatingMenu/autoDiscoverPresets.js +15 -0
- package/lib/module/floatingMenu/defaultConfig.js +14 -7
- package/lib/module/floatingMenu/dial/DialDevTools.js +8 -2
- package/lib/module/floatingMenu/dial/DialDevTools.web.js +590 -0
- package/lib/module/floatingMenu/dial/OnboardingTooltip.js +2 -2
- package/lib/module/floatingMenu/floatingTools.web.js +357 -0
- package/lib/module/index.js +2 -2
- package/lib/module/index.web.js +24 -0
- package/lib/module/utils/autoDiscoverPresets.web.js +174 -0
- package/lib/typescript/commonjs/floatingMenu/DevToolsSettingsModal.d.ts.map +1 -1
- package/lib/typescript/commonjs/floatingMenu/DevToolsSettingsModal.web.d.ts +23 -0
- package/lib/typescript/commonjs/floatingMenu/DevToolsSettingsModal.web.d.ts.map +1 -0
- package/lib/typescript/commonjs/floatingMenu/FloatingDevTools.d.ts +1 -1
- package/lib/typescript/commonjs/floatingMenu/FloatingDevTools.d.ts.map +1 -1
- package/lib/typescript/commonjs/floatingMenu/FloatingDevTools.web.d.ts +48 -0
- package/lib/typescript/commonjs/floatingMenu/FloatingDevTools.web.d.ts.map +1 -0
- package/lib/typescript/commonjs/floatingMenu/FloatingMenu.d.ts.map +1 -1
- package/lib/typescript/commonjs/floatingMenu/autoDiscoverPresets.d.ts.map +1 -1
- package/lib/typescript/commonjs/floatingMenu/defaultConfig.d.ts +8 -7
- package/lib/typescript/commonjs/floatingMenu/defaultConfig.d.ts.map +1 -1
- package/lib/typescript/commonjs/floatingMenu/dial/DialDevTools.d.ts.map +1 -1
- package/lib/typescript/commonjs/floatingMenu/dial/DialDevTools.web.d.ts +26 -0
- package/lib/typescript/commonjs/floatingMenu/dial/DialDevTools.web.d.ts.map +1 -0
- package/lib/typescript/commonjs/floatingMenu/dial/OnboardingTooltip.d.ts +1 -1
- package/lib/typescript/commonjs/floatingMenu/dial/OnboardingTooltip.d.ts.map +1 -1
- package/lib/typescript/commonjs/floatingMenu/floatingTools.web.d.ts +27 -0
- package/lib/typescript/commonjs/floatingMenu/floatingTools.web.d.ts.map +1 -0
- package/lib/typescript/commonjs/index.web.d.ts +20 -0
- package/lib/typescript/commonjs/index.web.d.ts.map +1 -0
- package/lib/typescript/commonjs/utils/autoDiscoverPresets.web.d.ts +58 -0
- package/lib/typescript/commonjs/utils/autoDiscoverPresets.web.d.ts.map +1 -0
- package/lib/typescript/module/floatingMenu/DevToolsSettingsModal.d.ts.map +1 -1
- package/lib/typescript/module/floatingMenu/DevToolsSettingsModal.web.d.ts +23 -0
- package/lib/typescript/module/floatingMenu/DevToolsSettingsModal.web.d.ts.map +1 -0
- package/lib/typescript/module/floatingMenu/FloatingDevTools.d.ts +1 -1
- package/lib/typescript/module/floatingMenu/FloatingDevTools.d.ts.map +1 -1
- package/lib/typescript/module/floatingMenu/FloatingDevTools.web.d.ts +48 -0
- package/lib/typescript/module/floatingMenu/FloatingDevTools.web.d.ts.map +1 -0
- package/lib/typescript/module/floatingMenu/FloatingMenu.d.ts.map +1 -1
- package/lib/typescript/module/floatingMenu/autoDiscoverPresets.d.ts.map +1 -1
- package/lib/typescript/module/floatingMenu/defaultConfig.d.ts +8 -7
- package/lib/typescript/module/floatingMenu/defaultConfig.d.ts.map +1 -1
- package/lib/typescript/module/floatingMenu/dial/DialDevTools.d.ts.map +1 -1
- package/lib/typescript/module/floatingMenu/dial/DialDevTools.web.d.ts +26 -0
- package/lib/typescript/module/floatingMenu/dial/DialDevTools.web.d.ts.map +1 -0
- package/lib/typescript/module/floatingMenu/dial/OnboardingTooltip.d.ts +1 -1
- package/lib/typescript/module/floatingMenu/dial/OnboardingTooltip.d.ts.map +1 -1
- package/lib/typescript/module/floatingMenu/floatingTools.web.d.ts +27 -0
- package/lib/typescript/module/floatingMenu/floatingTools.web.d.ts.map +1 -0
- package/lib/typescript/module/index.web.d.ts +20 -0
- package/lib/typescript/module/index.web.d.ts.map +1 -0
- package/lib/typescript/module/utils/autoDiscoverPresets.web.d.ts +58 -0
- package/lib/typescript/module/utils/autoDiscoverPresets.web.d.ts.map +1 -0
- package/package.json +5 -4
|
@@ -9,7 +9,7 @@ var _react = _interopRequireWildcard(require("react"));
|
|
|
9
9
|
var _reactNative = require("react-native");
|
|
10
10
|
var _AppHostLogic = require("./AppHostLogic.js");
|
|
11
11
|
var _MinimizedToolsContext = require("./MinimizedToolsContext.js");
|
|
12
|
-
var _DevToolsSettingsModal = require("./DevToolsSettingsModal
|
|
12
|
+
var _DevToolsSettingsModal = require("./DevToolsSettingsModal");
|
|
13
13
|
var _jsxRuntime = require("react/jsx-runtime");
|
|
14
14
|
function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function (e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != typeof e && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (const t in e) "default" !== t && {}.hasOwnProperty.call(e, t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, t)) && (i.get || i.set) ? o(f, t, i) : f[t] = e[t]); return f; })(e, t); }
|
|
15
15
|
const AppHostContext = /*#__PURE__*/(0, _react.createContext)(null);
|
|
@@ -114,6 +114,7 @@ const mergeWithDefaults = (defaults, stored, options) => {
|
|
|
114
114
|
* @param availableApps - List of available apps from auto-discovery
|
|
115
115
|
* @param defaultFloatingTools - Optional array of tool IDs to enable by default in floating bubble
|
|
116
116
|
* @param defaultDialTools - Optional array of tool IDs to enable by default in dial menu
|
|
117
|
+
* If not provided, all dial-compatible tools are enabled by default (up to 6)
|
|
117
118
|
*/
|
|
118
119
|
const generateDefaultSettings = (availableApps = [], defaultFloatingTools, defaultDialTools) => {
|
|
119
120
|
const dialDefaults = {};
|
|
@@ -123,14 +124,17 @@ const generateDefaultSettings = (availableApps = [], defaultFloatingTools, defau
|
|
|
123
124
|
// Cast to Set<string> to allow comparison with any tool ID (including custom tools)
|
|
124
125
|
const enabledFloatingSet = new Set(defaultFloatingTools ?? []);
|
|
125
126
|
const enabledDialSet = new Set(defaultDialTools ?? []);
|
|
127
|
+
|
|
128
|
+
// If no defaultDialTools specified, auto-enable all dial-compatible tools
|
|
129
|
+
const autoEnableDialTools = !defaultDialTools || defaultDialTools.length === 0;
|
|
126
130
|
for (const app of availableApps) {
|
|
127
131
|
const {
|
|
128
132
|
id,
|
|
129
133
|
slot = "both"
|
|
130
134
|
} = app;
|
|
131
135
|
if (slot === "dial" || slot === "both") {
|
|
132
|
-
//
|
|
133
|
-
dialDefaults[id] = enabledDialSet.has(id);
|
|
136
|
+
// Auto-enable if no defaults specified, otherwise check the set
|
|
137
|
+
dialDefaults[id] = autoEnableDialTools ? true : enabledDialSet.has(id);
|
|
134
138
|
}
|
|
135
139
|
if (slot === "row" || slot === "both") {
|
|
136
140
|
// Enable if in defaultFloatingTools, otherwise false
|
|
@@ -521,6 +525,10 @@ const DevToolsSettingsModal = ({
|
|
|
521
525
|
size: 16,
|
|
522
526
|
color: _sharedUi.buoyColors.textSecondary
|
|
523
527
|
});
|
|
528
|
+
case "redux":
|
|
529
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_floatingToolsCore.ReduxIcon, {
|
|
530
|
+
size: 16
|
|
531
|
+
});
|
|
524
532
|
default:
|
|
525
533
|
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_sharedUi.Info, {
|
|
526
534
|
size: 16,
|
|
@@ -909,13 +917,10 @@ const DevToolsSettingsModal = ({
|
|
|
909
917
|
style: styles.exportHintBanner,
|
|
910
918
|
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_sharedUi.Zap, {
|
|
911
919
|
size: 14,
|
|
912
|
-
color: _sharedUi.buoyColors.
|
|
913
|
-
}), /*#__PURE__*/(0, _jsxRuntime.
|
|
920
|
+
color: _sharedUi.buoyColors.textMuted
|
|
921
|
+
}), /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
|
|
914
922
|
style: styles.exportHintText,
|
|
915
|
-
children:
|
|
916
|
-
style: styles.exportHintBold,
|
|
917
|
-
children: "New!"
|
|
918
|
-
}), " Configure your tools above, then export to set team defaults."]
|
|
923
|
+
children: "Configure tools, then export as props for your team."
|
|
919
924
|
})]
|
|
920
925
|
}), isExportExpanded && /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
|
|
921
926
|
style: styles.exportCodeContainer,
|
|
@@ -1373,12 +1378,19 @@ const basicDefaultSettings = {
|
|
|
1373
1378
|
/**
|
|
1374
1379
|
* Creates default settings from the team configuration arrays.
|
|
1375
1380
|
* Used by the hook when no stored settings exist.
|
|
1381
|
+
*
|
|
1382
|
+
* Note: This function doesn't have access to availableApps, so it can only
|
|
1383
|
+
* enable tools that are explicitly listed in the config arrays.
|
|
1384
|
+
* For auto-enabling all dial tools, the generateDefaultSettings function
|
|
1385
|
+
* (which has access to availableApps) handles that case.
|
|
1376
1386
|
*/
|
|
1377
1387
|
const createDefaultsFromConfig = (defaultFloatingTools, defaultDialTools) => {
|
|
1378
1388
|
const floatingSet = new Set(defaultFloatingTools ?? []);
|
|
1379
1389
|
const dialSet = new Set(defaultDialTools ?? []);
|
|
1380
1390
|
|
|
1381
1391
|
// Build dial tools record from defaults
|
|
1392
|
+
// Note: If no defaults specified, dialTools will be empty here
|
|
1393
|
+
// but generateDefaultSettings will auto-enable all tools when it has access to availableApps
|
|
1382
1394
|
const dialTools = {};
|
|
1383
1395
|
for (const id of dialSet) {
|
|
1384
1396
|
dialTools[id] = true;
|