@tedi-design-system/react 15.0.0-rc.12 → 15.0.0-rc.14
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/_virtual/index.cjs10.js +1 -1
- package/_virtual/index.cjs11.js +1 -1
- package/_virtual/index.cjs12.js +1 -1
- package/_virtual/index.cjs13.js +1 -1
- package/_virtual/index.cjs5.js +1 -1
- package/_virtual/index.cjs6.js +1 -1
- package/_virtual/index.cjs7.js +1 -1
- package/_virtual/index.cjs8.js +1 -1
- package/_virtual/index.cjs9.js +1 -1
- package/_virtual/index.es10.js +1 -1
- package/_virtual/index.es11.js +1 -1
- package/_virtual/index.es12.js +1 -1
- package/_virtual/index.es13.js +4 -2
- package/_virtual/index.es5.js +2 -4
- package/_virtual/index.es6.js +1 -1
- package/_virtual/index.es7.js +1 -1
- package/_virtual/index.es8.js +1 -1
- package/_virtual/index.es9.js +1 -1
- package/bundle-stats.html +1 -1
- package/external/@mui/system/colorManipulator.cjs.js +1 -1
- package/external/@mui/system/colorManipulator.es.js +2 -2
- package/external/@mui/system/createStyled.cjs.js +1 -1
- package/external/@mui/system/createStyled.es.js +6 -6
- package/external/@mui/system/useThemeWithoutDefault.cjs.js +1 -1
- package/external/@mui/system/useThemeWithoutDefault.es.js +1 -1
- package/external/toposort/index.cjs.js +1 -1
- package/external/toposort/index.es.js +1 -1
- package/index.css +1 -1
- package/package.json +1 -1
- package/src/tedi/components/content/text-group/text-group.cjs.js +1 -1
- package/src/tedi/components/content/text-group/text-group.d.ts +25 -5
- package/src/tedi/components/content/text-group/text-group.es.js +15 -14
- package/src/tedi/components/content/text-group/text-group.module.scss.cjs.js +1 -1
- package/src/tedi/components/content/text-group/text-group.module.scss.es.js +3 -1
package/package.json
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("react/jsx-runtime"),a=require("../../../../../external/classnames/index.cjs.js"),x=require("../label/label.cjs.js"),e=require("./text-group.module.scss.cjs.js"),f=require("../../../helpers/hooks/use-breakpoint-props.cjs.js"),b=u=>{const{getCurrentBreakpointProps:o}=f.useBreakpointProps(u.defaultServerBreakpoint),{label:l,value:s,labelWidth:r="auto",className:i,type:d="vertical",labelAlign:n="left"}=o(u),c=a.default(e.default["tedi-text-group"],e.default[`tedi-text-group--${d}`],i),p=typeof r=="number"?`${r}%`:r;return t.jsxs("dl",{className:c,style:{"--label-width":p},children:[t.jsx("dt",{className:a.default(e.default["tedi-text-group__label"],e.default[`tedi-text-group--align-${n}`]),children:typeof l=="string"?t.jsx(x.Label,{children:l}):l}),t.jsx("dd",{className:a.default(e.default["tedi-text-group__value"]),children:s})]})};exports.TextGroup=b;
|
|
@@ -1,22 +1,42 @@
|
|
|
1
1
|
import { default as React } from 'react';
|
|
2
2
|
import { BreakpointSupport } from '../../../helpers';
|
|
3
|
-
type
|
|
3
|
+
type TextAlign = 'left' | 'right';
|
|
4
4
|
type TextGroupBreakpointProps = {
|
|
5
5
|
/**
|
|
6
6
|
* Type of text group layout
|
|
7
7
|
*/
|
|
8
|
-
type?:
|
|
8
|
+
type?: 'horizontal';
|
|
9
|
+
/**
|
|
10
|
+
* Alignment for the label text
|
|
11
|
+
* @default 'left'
|
|
12
|
+
*/
|
|
13
|
+
labelAlign?: TextAlign;
|
|
14
|
+
/**
|
|
15
|
+
* Width for the label (e.g., '200px', '30%', etc.)
|
|
16
|
+
* @default 'auto'
|
|
17
|
+
*/
|
|
18
|
+
labelWidth?: string | number;
|
|
19
|
+
} | {
|
|
20
|
+
/**
|
|
21
|
+
* Type of text group layout
|
|
22
|
+
*/
|
|
23
|
+
type: 'vertical';
|
|
24
|
+
/**
|
|
25
|
+
* Alignment for the label text
|
|
26
|
+
* @default 'left'
|
|
27
|
+
*/
|
|
28
|
+
labelAlign?: 'left';
|
|
9
29
|
/**
|
|
10
30
|
* Width for the label (e.g., '200px', '30%', etc.)
|
|
11
31
|
* @default 'auto'
|
|
12
32
|
*/
|
|
13
33
|
labelWidth?: string | number;
|
|
14
34
|
};
|
|
15
|
-
export
|
|
35
|
+
export type TextGroupProps = BreakpointSupport<TextGroupBreakpointProps> & {
|
|
16
36
|
/**
|
|
17
37
|
* Label for the text group
|
|
18
38
|
*/
|
|
19
|
-
label:
|
|
39
|
+
label: React.ReactNode;
|
|
20
40
|
/**
|
|
21
41
|
* Value displayed alongside the label
|
|
22
42
|
*/
|
|
@@ -25,6 +45,6 @@ export interface TextGroupProps extends BreakpointSupport<TextGroupBreakpointPro
|
|
|
25
45
|
* Additional class name(s) to apply to the element
|
|
26
46
|
*/
|
|
27
47
|
className?: string;
|
|
28
|
-
}
|
|
48
|
+
};
|
|
29
49
|
export declare const TextGroup: (props: TextGroupProps) => JSX.Element;
|
|
30
50
|
export {};
|
|
@@ -1,21 +1,22 @@
|
|
|
1
|
-
import { jsxs as
|
|
2
|
-
import
|
|
3
|
-
import { Label as
|
|
1
|
+
import { jsxs as u, jsx as l } from "react/jsx-runtime";
|
|
2
|
+
import o from "../../../../../external/classnames/index.es.js";
|
|
3
|
+
import { Label as x } from "../label/label.es.js";
|
|
4
4
|
import e from "./text-group.module.scss.es.js";
|
|
5
|
-
import { useBreakpointProps as
|
|
6
|
-
const
|
|
7
|
-
const { getCurrentBreakpointProps:
|
|
8
|
-
label:
|
|
5
|
+
import { useBreakpointProps as f } from "../../../helpers/hooks/use-breakpoint-props.es.js";
|
|
6
|
+
const v = (a) => {
|
|
7
|
+
const { getCurrentBreakpointProps: s } = f(a.defaultServerBreakpoint), {
|
|
8
|
+
label: t,
|
|
9
9
|
value: i,
|
|
10
|
-
labelWidth:
|
|
10
|
+
labelWidth: r = "auto",
|
|
11
11
|
className: p,
|
|
12
|
-
type:
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
/* @__PURE__ */
|
|
12
|
+
type: n = "vertical",
|
|
13
|
+
labelAlign: d = "left"
|
|
14
|
+
} = s(a), m = o(e["tedi-text-group"], e[`tedi-text-group--${n}`], p), c = typeof r == "number" ? `${r}%` : r;
|
|
15
|
+
return /* @__PURE__ */ u("dl", { className: m, style: { "--label-width": c }, children: [
|
|
16
|
+
/* @__PURE__ */ l("dt", { className: o(e["tedi-text-group__label"], e[`tedi-text-group--align-${d}`]), children: typeof t == "string" ? /* @__PURE__ */ l(x, { children: t }) : t }),
|
|
17
|
+
/* @__PURE__ */ l("dd", { className: o(e["tedi-text-group__value"]), children: i })
|
|
17
18
|
] });
|
|
18
19
|
};
|
|
19
20
|
export {
|
|
20
|
-
|
|
21
|
+
v as TextGroup
|
|
21
22
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const t={"tedi-text-group":"tedi-text-group-be3b15d8","tedi-text-group--horizontal":"tedi-text-group--horizontal-9d91c910","tedi-text-group__label":"tedi-text-group__label-a8904597","tedi-text-group__value":"tedi-text-group__value-4bbf1a22"};exports.default=t;
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const t={"tedi-text-group":"tedi-text-group-be3b15d8","tedi-text-group--horizontal":"tedi-text-group--horizontal-9d91c910","tedi-text-group__label":"tedi-text-group__label-a8904597","tedi-text-group__value":"tedi-text-group__value-4bbf1a22","tedi-text-group--align-left":"tedi-text-group--align-left-cc82fd31","tedi-text-group--align-right":"tedi-text-group--align-right-0eebe973"};exports.default=t;
|
|
@@ -2,7 +2,9 @@ const t = {
|
|
|
2
2
|
"tedi-text-group": "tedi-text-group-be3b15d8",
|
|
3
3
|
"tedi-text-group--horizontal": "tedi-text-group--horizontal-9d91c910",
|
|
4
4
|
"tedi-text-group__label": "tedi-text-group__label-a8904597",
|
|
5
|
-
"tedi-text-group__value": "tedi-text-group__value-4bbf1a22"
|
|
5
|
+
"tedi-text-group__value": "tedi-text-group__value-4bbf1a22",
|
|
6
|
+
"tedi-text-group--align-left": "tedi-text-group--align-left-cc82fd31",
|
|
7
|
+
"tedi-text-group--align-right": "tedi-text-group--align-right-0eebe973"
|
|
6
8
|
};
|
|
7
9
|
export {
|
|
8
10
|
t as default
|