@dbcdk/react-components 0.0.212 → 0.0.213

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.
@@ -34,7 +34,7 @@ function InputContainer({
34
34
  required && /* @__PURE__ */ jsxRuntime.jsx("span", { className: styles__default.default.required, children: " *" })
35
35
  ] }),
36
36
  withModifiedTag && modifiedTag,
37
- labelAction && /* @__PURE__ */ jsxRuntime.jsx("span", { "data-input-container-label-action": "true", children: labelAction })
37
+ labelAction && /* @__PURE__ */ jsxRuntime.jsx("span", { className: styles__default.default.labelAction, "data-input-container-label-action": "true", children: labelAction })
38
38
  ] });
39
39
  const renderLabelRow = orientation === "vertical" ? labelRow(true) : modifiedTag ? /* @__PURE__ */ jsxRuntime.jsxs("div", { className: styles__default.default.horizontalLabel, children: [
40
40
  labelRow(false),
@@ -28,7 +28,7 @@ function InputContainer({
28
28
  required && /* @__PURE__ */ jsx("span", { className: styles.required, children: " *" })
29
29
  ] }),
30
30
  withModifiedTag && modifiedTag,
31
- labelAction && /* @__PURE__ */ jsx("span", { "data-input-container-label-action": "true", children: labelAction })
31
+ labelAction && /* @__PURE__ */ jsx("span", { className: styles.labelAction, "data-input-container-label-action": "true", children: labelAction })
32
32
  ] });
33
33
  const renderLabelRow = orientation === "vertical" ? labelRow(true) : modifiedTag ? /* @__PURE__ */ jsxs("div", { className: styles.horizontalLabel, children: [
34
34
  labelRow(false),
@@ -16,6 +16,15 @@
16
16
  font-weight: var(--font-weight-medium);
17
17
  }
18
18
 
19
+ /* Fills the rest of the label row like Headline's addition, so the content can
20
+ position itself, e.g. <Stack grow justify="end"> or dbc-ms-auto. */
21
+ .labelAction {
22
+ display: flex;
23
+ flex: 1 1 auto;
24
+ min-width: 0;
25
+ align-items: center;
26
+ }
27
+
19
28
  .horizontal .errorText,
20
29
  .horizontal .helpText {
21
30
  margin-left: calc(var(--label-width) + var(--gap));
@@ -38,7 +47,9 @@
38
47
  white-space: nowrap;
39
48
  }
40
49
 
41
- .horizontal label {
50
+ /* Only the field's own label: a bare `label` selector also sized labels inside
51
+ the control or the label action, e.g. a Switch's text. */
52
+ .horizontal .label {
42
53
  width: var(--label-width);
43
54
  }
44
55
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dbcdk/react-components",
3
- "version": "0.0.212",
3
+ "version": "0.0.213",
4
4
  "description": "Reusable React components for DBC projects",
5
5
  "license": "ISC",
6
6
  "author": "",