@motifx-community/ui 0.1.0-beta.19 → 0.1.0-beta.20

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.
Files changed (199) hide show
  1. package/CHANGELOG.md +21 -0
  2. package/dist/components/layout/SplitContainer.d.ts +6 -4
  3. package/dist/components/layout/split-container-props.d.ts +7 -4
  4. package/dist/index.js +21 -8
  5. package/dist/index.js.map +1 -1
  6. package/dist/styles.css +25 -0
  7. package/docs/accordion.md +1 -1
  8. package/docs/actionsheet.md +1 -1
  9. package/docs/appbar.md +1 -1
  10. package/docs/appmenu-api.md +1 -1
  11. package/docs/appmenu-programmatic.md +1 -1
  12. package/docs/appmenu-search.md +1 -1
  13. package/docs/appmenu.md +1 -1
  14. package/docs/avatar.md +1 -1
  15. package/docs/badge.md +1 -1
  16. package/docs/bar-gauge-angles.md +1 -1
  17. package/docs/bar-gauge-data.md +1 -1
  18. package/docs/bar-gauge-labels.md +1 -1
  19. package/docs/bar-gauge.md +1 -1
  20. package/docs/barcode.md +1 -1
  21. package/docs/bottomnavigation.md +1 -1
  22. package/docs/bottomsheet.md +1 -1
  23. package/docs/breadcrumb.md +1 -1
  24. package/docs/button.md +1 -1
  25. package/docs/buttongroup.md +1 -1
  26. package/docs/buttons.md +1 -1
  27. package/docs/calendar.md +1 -1
  28. package/docs/card.md +33 -2
  29. package/docs/chart-bars.md +1 -1
  30. package/docs/chart-candles.md +1 -1
  31. package/docs/chart-funnel.md +1 -1
  32. package/docs/chart-heatmap.md +1 -1
  33. package/docs/chart-lines.md +1 -1
  34. package/docs/chart-live.md +1 -1
  35. package/docs/chart-pie.md +1 -1
  36. package/docs/chart-radar.md +1 -1
  37. package/docs/chart-ranges.md +1 -1
  38. package/docs/chart-references.md +1 -1
  39. package/docs/chart-scatter.md +1 -1
  40. package/docs/chart-waterfall.md +1 -1
  41. package/docs/chart-zoom.md +1 -1
  42. package/docs/chart.md +1 -1
  43. package/docs/chat.md +1 -1
  44. package/docs/checkbox.md +1 -1
  45. package/docs/chip.md +1 -1
  46. package/docs/choice.md +1 -1
  47. package/docs/colorbox.md +1 -1
  48. package/docs/combobox.md +1 -1
  49. package/docs/commands.md +1 -1
  50. package/docs/control.md +1 -1
  51. package/docs/data.md +1 -1
  52. package/docs/datagrid-api.md +1 -1
  53. package/docs/datagrid-bands.md +1 -1
  54. package/docs/datagrid-drag-select.md +1 -1
  55. package/docs/datagrid-drag.md +1 -1
  56. package/docs/datagrid-editing.md +1 -1
  57. package/docs/datagrid-filtering.md +1 -1
  58. package/docs/datagrid-forms.md +1 -1
  59. package/docs/datagrid-grouping.md +1 -1
  60. package/docs/datagrid-layout.md +1 -1
  61. package/docs/datagrid-lookups.md +1 -1
  62. package/docs/datagrid-master-detail.md +1 -1
  63. package/docs/datagrid-scrolling.md +1 -1
  64. package/docs/datagrid-selection.md +1 -1
  65. package/docs/datagrid.md +1 -1
  66. package/docs/datebox.md +1 -1
  67. package/docs/daterangebox.md +1 -1
  68. package/docs/diagram-api.md +1 -1
  69. package/docs/diagram-commands.md +1 -1
  70. package/docs/diagram-connections.md +1 -1
  71. package/docs/diagram-custom-nodes.md +1 -1
  72. package/docs/diagram-designer.md +1 -1
  73. package/docs/diagram-editing.md +1 -1
  74. package/docs/diagram-flow.md +1 -1
  75. package/docs/diagram-keyboard.md +1 -1
  76. package/docs/diagram-layout.md +1 -1
  77. package/docs/diagram-nodes.md +1 -1
  78. package/docs/diagram-tables.md +1 -1
  79. package/docs/diagram.md +1 -1
  80. package/docs/display.md +1 -1
  81. package/docs/draggable.md +1 -1
  82. package/docs/drawer.md +1 -1
  83. package/docs/dropdown.md +1 -1
  84. package/docs/editors.md +1 -1
  85. package/docs/expressioneditor.md +1 -1
  86. package/docs/expressions.md +1 -1
  87. package/docs/feedback.md +1 -1
  88. package/docs/fileuploader.md +1 -1
  89. package/docs/filterbuilder.md +1 -1
  90. package/docs/formlayout-schema.md +1 -1
  91. package/docs/formlayout.md +1 -1
  92. package/docs/foundations.md +1 -1
  93. package/docs/gallery.md +1 -1
  94. package/docs/gauge-base.md +1 -1
  95. package/docs/gauge-circular.md +1 -1
  96. package/docs/gauge-dashboards.md +1 -1
  97. package/docs/gauge-linear.md +1 -1
  98. package/docs/gauge-markers.md +1 -1
  99. package/docs/gauge-marks.md +1 -1
  100. package/docs/gauge-ranges.md +1 -1
  101. package/docs/gauge-scales.md +1 -1
  102. package/docs/gauge.md +1 -1
  103. package/docs/home.md +1 -1
  104. package/docs/keyboard.md +1 -1
  105. package/docs/language.md +1 -1
  106. package/docs/layout.md +3 -3
  107. package/docs/listbox.md +1 -1
  108. package/docs/loadpanel.md +1 -1
  109. package/docs/lookup.md +1 -1
  110. package/docs/markdown.md +1 -1
  111. package/docs/menus-api.md +1 -1
  112. package/docs/menus-context.md +1 -1
  113. package/docs/menus-customization.md +1 -1
  114. package/docs/menus-merging.md +1 -1
  115. package/docs/menus-programmatic.md +1 -1
  116. package/docs/menus.md +1 -1
  117. package/docs/multiview.md +1 -1
  118. package/docs/navigation.md +1 -1
  119. package/docs/numberbox.md +1 -1
  120. package/docs/otpinput.md +1 -1
  121. package/docs/pagination.md +1 -1
  122. package/docs/pivotgrid-api.md +1 -1
  123. package/docs/pivotgrid-chart.md +1 -1
  124. package/docs/pivotgrid-drilldown.md +1 -1
  125. package/docs/pivotgrid-export.md +1 -1
  126. package/docs/pivotgrid-fields.md +1 -1
  127. package/docs/pivotgrid-keyboard.md +1 -1
  128. package/docs/pivotgrid-layout.md +1 -1
  129. package/docs/pivotgrid-panel.md +1 -1
  130. package/docs/pivotgrid-remote.md +1 -1
  131. package/docs/pivotgrid-sorting.md +1 -1
  132. package/docs/pivotgrid-state.md +1 -1
  133. package/docs/pivotgrid-summaries.md +1 -1
  134. package/docs/pivotgrid.md +1 -1
  135. package/docs/popover.md +1 -1
  136. package/docs/progress.md +1 -1
  137. package/docs/qrcode.md +1 -1
  138. package/docs/radiogroup.md +1 -1
  139. package/docs/rating.md +1 -1
  140. package/docs/resizable.md +1 -1
  141. package/docs/ribbonmenu-api.md +1 -1
  142. package/docs/ribbonmenu-commands.md +1 -1
  143. package/docs/ribbonmenu-customization.md +1 -1
  144. package/docs/ribbonmenu-display.md +1 -1
  145. package/docs/ribbonmenu-layouts.md +1 -1
  146. package/docs/ribbonmenu-programmatic.md +1 -1
  147. package/docs/ribbonmenu.md +1 -1
  148. package/docs/scheduler-agenda.md +1 -1
  149. package/docs/scheduler-big-data.md +1 -1
  150. package/docs/scheduler-editing.md +1 -1
  151. package/docs/scheduler-form.md +1 -1
  152. package/docs/scheduler-icalendar.md +1 -1
  153. package/docs/scheduler-mobile.md +1 -1
  154. package/docs/scheduler-recurrence.md +1 -1
  155. package/docs/scheduler-resources.md +1 -1
  156. package/docs/scheduler-timeline.md +1 -1
  157. package/docs/scheduler.md +1 -1
  158. package/docs/scrollview.md +1 -1
  159. package/docs/shortcuteditor.md +1 -1
  160. package/docs/showcase-flowstudio.md +1 -1
  161. package/docs/showcase-home.md +1 -1
  162. package/docs/showcase-mail.md +1 -1
  163. package/docs/showcase.md +1 -1
  164. package/docs/signature.md +1 -1
  165. package/docs/skeleton.md +1 -1
  166. package/docs/slider.md +1 -1
  167. package/docs/sortable.md +1 -1
  168. package/docs/sparkline.md +1 -1
  169. package/docs/speeddial.md +1 -1
  170. package/docs/splitter.md +1 -1
  171. package/docs/stepper.md +1 -1
  172. package/docs/switch.md +1 -1
  173. package/docs/tabdocs-dock.md +1 -1
  174. package/docs/tabdocs-drag.md +1 -1
  175. package/docs/tabdocs-menus.md +1 -1
  176. package/docs/tabdocs-mobile.md +1 -1
  177. package/docs/tabdocs-tabs.md +1 -1
  178. package/docs/tabdocs-windows.md +1 -1
  179. package/docs/tabdocs-workspace.md +1 -1
  180. package/docs/tabdocs.md +1 -1
  181. package/docs/tabs.md +1 -1
  182. package/docs/tagbox.md +1 -1
  183. package/docs/textarea.md +1 -1
  184. package/docs/textbox.md +1 -1
  185. package/docs/tileview.md +1 -1
  186. package/docs/timeline.md +1 -1
  187. package/docs/toast.md +1 -1
  188. package/docs/tokens.md +1 -1
  189. package/docs/toolbar-api.md +1 -1
  190. package/docs/toolbar-customization.md +1 -1
  191. package/docs/toolbar.md +1 -1
  192. package/docs/tooltip.md +1 -1
  193. package/docs/treeview.md +1 -1
  194. package/docs/validationsummary.md +1 -1
  195. package/docs/window.md +1 -1
  196. package/docs/wizard.md +1 -1
  197. package/llms-full.txt +225 -194
  198. package/llms.txt +1 -1
  199. package/package.json +1 -1
package/CHANGELOG.md CHANGED
@@ -6,6 +6,27 @@ The format follows [Keep a Changelog](https://keepachangelog.com/en/1.1.0/) and
6
6
 
7
7
  ## [Unreleased]
8
8
 
9
+ ## [0.1.0-beta.20] - 2026-11-30
10
+
11
+ Needs `@motifx/core` 1.2.0-rc.31, `@motifx-community/data` 0.1.0-beta.3 and `@motifx-community/design-system`
12
+ 0.1.0-beta.4.
13
+
14
+ ### Added
15
+
16
+ - `firstMinSize` and `secondMinSize` of `SplitContainer` also take values per breakpoint (`{ xs: 120, md: 320 }`), so a
17
+ split that stacks its panes in a narrow room can ask less of them there (#10).
18
+
19
+ ### Changed
20
+
21
+ - `SplitContainer`: when the room cannot hold both minimum sizes, the panes share it in their proportion, instead of
22
+ the second pane keeping its minimum and the first going to almost nothing (#10).
23
+
24
+ ### Fixed
25
+
26
+ - `Card`: a `Toolbar` as the `action` no longer squeezes the title a few letters a line. The title and the toolbar
27
+ share the header evenly until either has all it needs, the title takes what is left, and the toolbar moves the items
28
+ that do not fit into its "more" menu (#11).
29
+
9
30
  ## [0.1.0-beta.19] - 2026-11-30
10
31
 
11
32
  Needs `@motifx/core` 1.2.0-rc.31, `@motifx-community/data` 0.1.0-beta.3 and `@motifx-community/design-system`
@@ -46,10 +46,10 @@ export declare class SplitContainer extends FocusContainer<HTMLDivElement, Split
46
46
  set value(value: SplitPosition);
47
47
  get fixedPanel(): SplitPanel;
48
48
  set fixedPanel(value: Bind<SplitPanel>);
49
- get firstMinSize(): number;
50
- set firstMinSize(value: Bind<number>);
51
- get secondMinSize(): number;
52
- set secondMinSize(value: Bind<number>);
49
+ get firstMinSize(): Responsive<number>;
50
+ set firstMinSize(value: Bind<Responsive<number>>);
51
+ get secondMinSize(): Responsive<number>;
52
+ set secondMinSize(value: Bind<Responsive<number>>);
53
53
  get collapsed(): SplitPanel;
54
54
  set collapsed(value: Bind<SplitPanel>);
55
55
  get resizable(): boolean;
@@ -71,6 +71,8 @@ export declare class SplitContainer extends FocusContainer<HTMLDivElement, Split
71
71
  private get parts();
72
72
  private createParts;
73
73
  private get horizontal();
74
+ /** The minimum sizes of the panes at the container's breakpoint now, in pixels. */
75
+ private get minSizes();
74
76
  /** A value at the container's breakpoint now: one per breakpoint starts following its width. */
75
77
  private at;
76
78
  private get breakpoints();
@@ -19,10 +19,13 @@ export interface SplitContainerProps extends ControlProps {
19
19
  * and the position is kept as a share.
20
20
  */
21
21
  fixedPanel?: Bind<SplitPanel>;
22
- /** The minimum size of the first pane, in pixels. The default is 0. */
23
- firstMinSize?: Bind<number>;
24
- /** The minimum size of the second pane, in pixels. The default is 0. */
25
- secondMinSize?: Bind<number>;
22
+ /**
23
+ * The minimum size of the first pane, in pixels, also per breakpoint (`{ xs: 120, md: 320 }`). The default is 0. When
24
+ * the room cannot hold both minimum sizes, the panes share it in their proportion.
25
+ */
26
+ firstMinSize?: Bind<Responsive<number>>;
27
+ /** The minimum size of the second pane, in pixels, also per breakpoint. The default is 0. */
28
+ secondMinSize?: Bind<Responsive<number>>;
26
29
  /** The hidden pane. The other pane takes all the space. The default is `'none'`. */
27
30
  collapsed?: Bind<SplitPanel>;
28
31
  /** Lets the pointer and keyboard move the splitter. The default is `true`. */
package/dist/index.js CHANGED
@@ -51349,7 +51349,7 @@ var ChartPlot = class {
51349
51349
  const wide = box.left - look.tickPad;
51350
51350
  positions.forEach((t, i) => {
51351
51351
  if (i % every) return;
51352
- this.xLabels.add(fit(t.text, rtl ? this.input.width - box.left - box.width - look.tickPad : wide, measure), beside, position.at(t.value) + baseline, besideAnchor);
51352
+ this.xLabels.add(fit$1(t.text, rtl ? this.input.width - box.left - box.width - look.tickPad : wide, measure), beside, position.at(t.value) + baseline, besideAnchor);
51353
51353
  });
51354
51354
  } else {
51355
51355
  const widest = Math.max(...positions.map((t) => measure(t.text)));
@@ -51763,7 +51763,7 @@ function markOf(s) {
51763
51763
  function overlaps$3(a, b) {
51764
51764
  return a.left < b.left + b.width && b.left < a.left + a.width && a.top < b.top + b.height && b.top < a.top + a.height;
51765
51765
  }
51766
- function fit(text, room, measure) {
51766
+ function fit$1(text, room, measure) {
51767
51767
  if (measure(text) <= room) return text;
51768
51768
  let end = 1;
51769
51769
  for (let at = text.length; at > 1; at--) if (measure(`${text.slice(0, at)}…`) <= room && end === 1) end = at;
@@ -131834,6 +131834,15 @@ var BREAKPOINTS$2 = Symbol("mx.split-container.breakpoints");
131834
131834
  function isShare(position) {
131835
131835
  return typeof position === "string" && position.trim().endsWith("%");
131836
131836
  }
131837
+ /** A minimum size as given: a number of pixels, no less than 0. */
131838
+ function minOf(value) {
131839
+ return Math.max(0, Number(value) || 0);
131840
+ }
131841
+ /** Minimum sizes the room cannot hold together share it in their proportion, so neither pane is squeezed to nothing. */
131842
+ function fit(min1, min2, room) {
131843
+ const total = min1 + min2;
131844
+ return total > room && min1 && min2 ? [room * min1 / total, room * min2 / total] : [min1, min2];
131845
+ }
131837
131846
  /** The CSS size of a position: pixels, a share of the room left by the splitter, or a length as written. */
131838
131847
  function sizeOf(position) {
131839
131848
  if (typeof position === "number") return `${position}px`;
@@ -131965,13 +131974,13 @@ var SplitContainer = class extends FocusContainer {
131965
131974
  return this.getProperty("firstMinSize") ?? 0;
131966
131975
  }
131967
131976
  set firstMinSize(value) {
131968
- this.assignProperty("firstMinSize", value, (v) => Math.max(0, Number(v) || 0));
131977
+ this.assignProperty("firstMinSize", value, (v) => isPerBreakpoint(v) ? v : minOf(v));
131969
131978
  }
131970
131979
  get secondMinSize() {
131971
131980
  return this.getProperty("secondMinSize") ?? 0;
131972
131981
  }
131973
131982
  set secondMinSize(value) {
131974
- this.assignProperty("secondMinSize", value, (v) => Math.max(0, Number(v) || 0));
131983
+ this.assignProperty("secondMinSize", value, (v) => isPerBreakpoint(v) ? v : minOf(v));
131975
131984
  }
131976
131985
  get collapsed() {
131977
131986
  return this.getProperty("collapsed") ?? "none";
@@ -132054,6 +132063,10 @@ var SplitContainer = class extends FocusContainer {
132054
132063
  get horizontal() {
132055
132064
  return this.at(this.peekProperty("orientation")) !== "vertical";
132056
132065
  }
132066
+ /** The minimum sizes of the panes at the container's breakpoint now, in pixels. */
132067
+ get minSizes() {
132068
+ return [minOf(this.at(this.peekProperty("firstMinSize"))), minOf(this.at(this.peekProperty("secondMinSize")))];
132069
+ }
132057
132070
  /** A value at the container's breakpoint now: one per breakpoint starts following its width. */
132058
132071
  at(value) {
132059
132072
  return isPerBreakpoint(value) ? this.breakpoints.pick(value) : value;
@@ -132087,10 +132100,11 @@ var SplitContainer = class extends FocusContainer {
132087
132100
  this.renderValue();
132088
132101
  }
132089
132102
  tracks(collapsed) {
132090
- const min1 = `${this.peekProperty("firstMinSize") ?? 0}px`;
132091
- const min2 = `${this.peekProperty("secondMinSize") ?? 0}px`;
132092
132103
  if (collapsed === "first") return `0px ${SPLITTER} minmax(0, 1fr)`;
132093
132104
  if (collapsed === "second") return `minmax(0, 1fr) ${SPLITTER} 0px`;
132105
+ const [one, two] = this.minSizes;
132106
+ const floor = (min) => one && two ? `min(${min}px, calc((100% - ${SPLITTER}) * ${Math.round(min / (one + two) * 1e4) / 1e4}))` : `${min}px`;
132107
+ const [min1, min2] = [floor(one), floor(two)];
132094
132108
  const size = sizeOf(this.peekProperty("position") ?? "50%");
132095
132109
  if (this.peekProperty("fixedPanel") === "second") return `minmax(0, 1fr) ${SPLITTER} clamp(${min2}, ${size}, calc(100% - ${min1} - ${SPLITTER}))`;
132096
132110
  return `clamp(${min1}, ${size}, calc(100% - ${min2} - ${SPLITTER})) ${SPLITTER} minmax(0, 1fr)`;
@@ -132112,8 +132126,7 @@ var SplitContainer = class extends FocusContainer {
132112
132126
  /** Puts the splitter so the first pane is `size` pixels of `room`, within the minimum sizes. */
132113
132127
  moveTo(size, room, fire) {
132114
132128
  if (!room) return;
132115
- const min1 = this.peekProperty("firstMinSize") ?? 0;
132116
- const min2 = this.peekProperty("secondMinSize") ?? 0;
132129
+ const [min1, min2] = fit(...this.minSizes, room);
132117
132130
  const first = Math.min(Math.max(size, min1), Math.max(min1, room - min2));
132118
132131
  const fixed = this.peekProperty("fixedPanel") ?? "none";
132119
132132
  const position = fixed === "none" ? `${Math.round(first / room * 1e4) / 100}%` : Math.round(fixed === "second" ? room - first : first);