@trops/dash-core 0.1.565 → 0.1.566

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.esm.js CHANGED
@@ -59133,27 +59133,23 @@ var DashboardConfigModal = function DashboardConfigModal(_ref) {
59133
59133
  });
59134
59134
  }
59135
59135
 
59136
- // Bulk-apply: write this provider as the binding for every widget of
59137
- // this type that doesn't already have an explicit widget-level override.
59136
+ // Bulk-apply: retarget every widget of this provider type to the
59137
+ // newly-chosen provider name. The header text above the dropdown
59138
+ // says "Apply one provider to every widget of this type, or adjust
59139
+ // per-widget below" — bulk is the retarget-everything action;
59140
+ // per-row overrides happen AFTER bulk if the user wants exceptions.
59138
59141
  //
59139
- // Override-detection consults the staged state first so a freshly
59140
- // staged unset is recognised as "no override" and gets bulked. A
59141
- // non-empty staged value is treated as an explicit pick and is
59142
- // preserved (bulk skips). Without this, the user could stage an
59143
- // unset and then click Bulk and the widget they just unset would
59144
- // be skipped because the *original* layer-1 value still lived on
59145
- // `b.layoutItem.selectedProviders`.
59142
+ // Previous behavior skipped rows that already had an explicit pick,
59143
+ // which meant the dropdown was a no-op when every row already had a
59144
+ // value (the common case: every Slack widget on a dashboard inherits
59145
+ // the same Slack provider). The user changing bulk from "Slack" to
59146
+ // "Slack Dash Comms" would see zero rows update and Save stay
59147
+ // disabled. The fill-blanks-only semantics fought the UI text and
59148
+ // the user's mental model — every spreadsheet-style bulk operation
59149
+ // overrides everything, with per-row tweaks happening afterward.
59146
59150
  function stageBulk(providerType, providerName) {
59147
59151
  var affected = effectiveBindings.filter(function (b) {
59148
- var _staged$b$widgetId2, _b$layoutItem;
59149
- if (b.providerType !== providerType) return false;
59150
- var stagedValue = (_staged$b$widgetId2 = staged[b.widgetId]) === null || _staged$b$widgetId2 === void 0 ? void 0 : _staged$b$widgetId2[providerType];
59151
- if (stagedValue !== undefined) {
59152
- // Empty/null staged value → user staged an unset → include
59153
- // in bulk. Non-empty → explicit pick, preserve it.
59154
- return !stagedValue;
59155
- }
59156
- return !((_b$layoutItem = b.layoutItem) !== null && _b$layoutItem !== void 0 && (_b$layoutItem = _b$layoutItem.selectedProviders) !== null && _b$layoutItem !== void 0 && _b$layoutItem[providerType]);
59152
+ return b.providerType === providerType;
59157
59153
  });
59158
59154
  setStaged(function (prev) {
59159
59155
  var next = _objectSpread$a({}, prev);