@mittwald/flow-react-components 0.2.0-alpha.877 → 0.2.0-alpha.879

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.
@@ -1,6 +1,7 @@
1
1
  "use client"
2
2
  /* */
3
3
  import { jsx } from 'react/jsx-runtime';
4
+ import { useId } from 'react';
4
5
  import styles from './LabeledValue.module.scss.mjs';
5
6
  import clsx from 'clsx';
6
7
  import '../../lib/propsContext/propsContext.mjs';
@@ -9,9 +10,12 @@ import { PropsContextProvider } from '../../lib/propsContext/components/PropsCon
9
10
  const LabeledValue = (props) => {
10
11
  const { children, className } = props;
11
12
  const rootClassName = clsx(styles.labeledValue, className);
13
+ const labelId = useId();
12
14
  const propsContext = {
13
15
  Label: {
14
- className: styles.label
16
+ className: styles.label,
17
+ elementType: "span",
18
+ id: labelId
15
19
  },
16
20
  CopyButton: {
17
21
  className: styles.button,
@@ -26,7 +30,7 @@ const LabeledValue = (props) => {
26
30
  inline: true
27
31
  }
28
32
  };
29
- return /* @__PURE__ */ jsx("div", { className: rootClassName, children: /* @__PURE__ */ jsx(PropsContextProvider, { props: propsContext, children }) });
33
+ return /* @__PURE__ */ jsx("div", { className: rootClassName, role: "group", "aria-labelledby": labelId, children: /* @__PURE__ */ jsx(PropsContextProvider, { props: propsContext, children }) });
30
34
  };
31
35
 
32
36
  export { LabeledValue };
@@ -1 +1 @@
1
- {"version":3,"file":"LabeledValue.mjs","sources":["../../../../../../../src/components/LabeledValue/LabeledValue.tsx"],"sourcesContent":["import type { FC, PropsWithChildren } from \"react\";\nimport styles from \"./LabeledValue.module.scss\";\nimport clsx from \"clsx\";\nimport type { PropsContext } from \"@/lib/propsContext\";\nimport { PropsContextProvider } from \"@/lib/propsContext\";\nimport type { PropsWithClassName } from \"@/lib/types/props\";\n\nexport interface LabeledValueProps\n extends PropsWithChildren, PropsWithClassName {}\n\n/** @flr-generate all */\nexport const LabeledValue: FC<LabeledValueProps> = (props) => {\n const { children, className } = props;\n\n const rootClassName = clsx(styles.labeledValue, className);\n\n const propsContext: PropsContext = {\n Label: {\n className: styles.label,\n },\n CopyButton: {\n className: styles.button,\n variant: \"plain\",\n size: \"s\",\n },\n Button: {\n className: styles.button,\n size: \"s\",\n },\n Link: {\n inline: true,\n },\n };\n\n return (\n <div className={rootClassName}>\n <PropsContextProvider props={propsContext}>\n {children}\n </PropsContextProvider>\n </div>\n );\n};\n\nexport default LabeledValue;\n"],"names":[],"mappings":";;;;;;AAWO,MAAM,YAAA,GAAsC,CAAC,KAAA,KAAU;AAC5D,EAAA,MAAM,EAAE,QAAA,EAAU,SAAA,EAAU,GAAI,KAAA;AAEhC,EAAA,MAAM,aAAA,GAAgB,IAAA,CAAK,MAAA,CAAO,YAAA,EAAc,SAAS,CAAA;AAEzD,EAAA,MAAM,YAAA,GAA6B;AAAA,IACjC,KAAA,EAAO;AAAA,MACL,WAAW,MAAA,CAAO;AAAA,KACpB;AAAA,IACA,UAAA,EAAY;AAAA,MACV,WAAW,MAAA,CAAO,MAAA;AAAA,MAClB,OAAA,EAAS,OAAA;AAAA,MACT,IAAA,EAAM;AAAA,KACR;AAAA,IACA,MAAA,EAAQ;AAAA,MACN,WAAW,MAAA,CAAO,MAAA;AAAA,MAClB,IAAA,EAAM;AAAA,KACR;AAAA,IACA,IAAA,EAAM;AAAA,MACJ,MAAA,EAAQ;AAAA;AACV,GACF;AAEA,EAAA,uBACE,GAAA,CAAC,SAAI,SAAA,EAAW,aAAA,EACd,8BAAC,oBAAA,EAAA,EAAqB,KAAA,EAAO,YAAA,EAC1B,QAAA,EACH,CAAA,EACF,CAAA;AAEJ;;;;"}
1
+ {"version":3,"file":"LabeledValue.mjs","sources":["../../../../../../../src/components/LabeledValue/LabeledValue.tsx"],"sourcesContent":["import { type FC, type PropsWithChildren, useId } from \"react\";\nimport styles from \"./LabeledValue.module.scss\";\nimport clsx from \"clsx\";\nimport type { PropsContext } from \"@/lib/propsContext\";\nimport { PropsContextProvider } from \"@/lib/propsContext\";\nimport type { PropsWithClassName } from \"@/lib/types/props\";\n\nexport interface LabeledValueProps\n extends PropsWithChildren, PropsWithClassName {}\n\n/** @flr-generate all */\nexport const LabeledValue: FC<LabeledValueProps> = (props) => {\n const { children, className } = props;\n\n const rootClassName = clsx(styles.labeledValue, className);\n\n const labelId = useId();\n\n const propsContext: PropsContext = {\n Label: {\n className: styles.label,\n elementType: \"span\",\n id: labelId,\n },\n CopyButton: {\n className: styles.button,\n variant: \"plain\",\n size: \"s\",\n },\n Button: {\n className: styles.button,\n size: \"s\",\n },\n Link: {\n inline: true,\n },\n };\n\n return (\n <div className={rootClassName} role=\"group\" aria-labelledby={labelId}>\n <PropsContextProvider props={propsContext}>\n {children}\n </PropsContextProvider>\n </div>\n );\n};\n\nexport default LabeledValue;\n"],"names":[],"mappings":";;;;;;;AAWO,MAAM,YAAA,GAAsC,CAAC,KAAA,KAAU;AAC5D,EAAA,MAAM,EAAE,QAAA,EAAU,SAAA,EAAU,GAAI,KAAA;AAEhC,EAAA,MAAM,aAAA,GAAgB,IAAA,CAAK,MAAA,CAAO,YAAA,EAAc,SAAS,CAAA;AAEzD,EAAA,MAAM,UAAU,KAAA,EAAM;AAEtB,EAAA,MAAM,YAAA,GAA6B;AAAA,IACjC,KAAA,EAAO;AAAA,MACL,WAAW,MAAA,CAAO,KAAA;AAAA,MAClB,WAAA,EAAa,MAAA;AAAA,MACb,EAAA,EAAI;AAAA,KACN;AAAA,IACA,UAAA,EAAY;AAAA,MACV,WAAW,MAAA,CAAO,MAAA;AAAA,MAClB,OAAA,EAAS,OAAA;AAAA,MACT,IAAA,EAAM;AAAA,KACR;AAAA,IACA,MAAA,EAAQ;AAAA,MACN,WAAW,MAAA,CAAO,MAAA;AAAA,MAClB,IAAA,EAAM;AAAA,KACR;AAAA,IACA,IAAA,EAAM;AAAA,MACJ,MAAA,EAAQ;AAAA;AACV,GACF;AAEA,EAAA,uBACE,GAAA,CAAC,KAAA,EAAA,EAAI,SAAA,EAAW,aAAA,EAAe,IAAA,EAAK,OAAA,EAAQ,iBAAA,EAAiB,OAAA,EAC3D,QAAA,kBAAA,GAAA,CAAC,oBAAA,EAAA,EAAqB,KAAA,EAAO,YAAA,EAC1B,UACH,CAAA,EACF,CAAA;AAEJ;;;;"}
@@ -1 +1 @@
1
- {"version":3,"file":"LabeledValue.d.ts","sourceRoot":"","sources":["../../../../src/components/LabeledValue/LabeledValue.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,EAAE,iBAAiB,EAAE,MAAM,OAAO,CAAC;AAKnD,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,mBAAmB,CAAC;AAE5D,MAAM,WAAW,iBACf,SAAQ,iBAAiB,EAAE,kBAAkB;CAAG;AAElD,wBAAwB;AACxB,eAAO,MAAM,YAAY,EAAE,EAAE,CAAC,iBAAiB,CA8B9C,CAAC;AAEF,eAAe,YAAY,CAAC"}
1
+ {"version":3,"file":"LabeledValue.d.ts","sourceRoot":"","sources":["../../../../src/components/LabeledValue/LabeledValue.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,EAAE,KAAK,iBAAiB,EAAS,MAAM,OAAO,CAAC;AAK/D,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,mBAAmB,CAAC;AAE5D,MAAM,WAAW,iBACf,SAAQ,iBAAiB,EAAE,kBAAkB;CAAG;AAElD,wBAAwB;AACxB,eAAO,MAAM,YAAY,EAAE,EAAE,CAAC,iBAAiB,CAkC9C,CAAC;AAEF,eAAe,YAAY,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mittwald/flow-react-components",
3
- "version": "0.2.0-alpha.877",
3
+ "version": "0.2.0-alpha.879",
4
4
  "type": "module",
5
5
  "description": "A React implementation of Flow, mittwald’s design system",
6
6
  "homepage": "https://mittwald.github.io/flow",
@@ -63,9 +63,9 @@
63
63
  "@internationalized/string": "^3.2.9",
64
64
  "@internationalized/string-compiler": "^3.4.1",
65
65
  "@lezer/highlight": "^1.2.3",
66
- "@mittwald/flow-icons": "0.2.0-alpha.877",
66
+ "@mittwald/flow-icons": "0.2.0-alpha.879",
67
67
  "@mittwald/password-tools-js": "3.0.0-alpha.30",
68
- "@mittwald/react-tunnel": "0.2.0-alpha.877",
68
+ "@mittwald/react-tunnel": "0.2.0-alpha.879",
69
69
  "@mittwald/react-use-promise": "^4.2.2",
70
70
  "@react-aria/form": "^3.2.1",
71
71
  "@react-aria/i18n": "^3.13.1",
@@ -120,7 +120,7 @@
120
120
  "@lezer/generator": "^1.8.0",
121
121
  "@lezer/lr": "^1.4.10",
122
122
  "@mittwald/flow-core": "",
123
- "@mittwald/flow-design-tokens": "0.2.0-alpha.877",
123
+ "@mittwald/flow-design-tokens": "0.2.0-alpha.879",
124
124
  "@mittwald/flow-icons-base": "",
125
125
  "@mittwald/react-use-promise": "^4.2.2",
126
126
  "@mittwald/remote-dom-react": "1.2.2-mittwald.10",
@@ -175,7 +175,7 @@
175
175
  },
176
176
  "peerDependencies": {
177
177
  "@internationalized/date": "^3.12.2",
178
- "@mittwald/flow-icons-pro": "0.2.0-alpha.876",
178
+ "@mittwald/flow-icons-pro": "0.2.0-alpha.878",
179
179
  "@mittwald/react-use-promise": "^4.2.2",
180
180
  "next": "^16.2.3",
181
181
  "react": "^19.2.0",
@@ -196,5 +196,5 @@
196
196
  "optional": true
197
197
  }
198
198
  },
199
- "gitHead": "b30248ccb92401149ae5658e5b4faab4957dcb04"
199
+ "gitHead": "f01211928eb9f9411735e2f45bcc96fcd0eafc34"
200
200
  }