import { TEXT_STYLE_PLUGIN as N } from "../../Plugins/TextStylePlugin/id.es.js";
const B = 12, a = 26, l = 124, D = (T) => T.map((e, c) => ({
  group: e,
  buttonGroupWidth: e.reduce(
    (_, t) => t.id === N ? l : a + _,
    B
  ),
  index: c
})), P = (T, e) => e.reduce((c, { group: _, buttonGroupWidth: t, index: s }) => {
  const n = Math.max(0, c.length - 1);
  return c[n] = c[n] ?? [], (c[n] ?? [{ actions: [], buttonGroupWidth: 0 }]).reduce(
    (O, { buttonGroupWidth: U }) => O + U,
    0
  ) + t <= T ? c[n].push({ group: _, buttonGroupWidth: t, index: s }) : c.push([{ group: _, buttonGroupWidth: t, index: s }]), c.filter((O) => O.length);
}, []);
export {
  D as getButtonGroupWidths,
  P as getButtonGroupsPerRow
};
//# sourceMappingURL=utils.es.js.map
