@kopexa/section-row 0.0.3 → 0.0.5

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.
@@ -7,11 +7,23 @@ import {
7
7
  } from "@kopexa/theme";
8
8
  import { jsx, jsxs } from "react/jsx-runtime";
9
9
  var SectionRow = (props) => {
10
- const { className, classNames, title, value, actions, info, ...rest } = props;
10
+ const {
11
+ className,
12
+ classNames,
13
+ title,
14
+ value,
15
+ actions,
16
+ orientation,
17
+ info,
18
+ spacing,
19
+ ...rest
20
+ } = props;
11
21
  const isValueString = typeof value === "string" || !value;
12
22
  const hasActions = !!actions;
13
23
  const styles = sectionRow({
14
- hasActions
24
+ hasActions,
25
+ orientation,
26
+ spacing
15
27
  });
16
28
  return /* @__PURE__ */ jsxs(
17
29
  "div",
@@ -21,7 +33,10 @@ var SectionRow = (props) => {
21
33
  }),
22
34
  ...rest,
23
35
  children: [
24
- /* @__PURE__ */ jsx("div", { className: styles.title({ className: classNames == null ? void 0 : classNames.title }), children: title }),
36
+ /* @__PURE__ */ jsxs("div", { className: styles.title({ className: classNames == null ? void 0 : classNames.title }), children: [
37
+ title,
38
+ info && /* @__PURE__ */ jsx("div", { className: styles.infoTip({ className: classNames == null ? void 0 : classNames.infoTip }), children: info })
39
+ ] }),
25
40
  /* @__PURE__ */ jsxs(
26
41
  "div",
27
42
  {
package/dist/index.js CHANGED
@@ -30,11 +30,23 @@ var import_shared_utils = require("@kopexa/shared-utils");
30
30
  var import_theme = require("@kopexa/theme");
31
31
  var import_jsx_runtime = require("react/jsx-runtime");
32
32
  var SectionRow = (props) => {
33
- const { className, classNames, title, value, actions, info, ...rest } = props;
33
+ const {
34
+ className,
35
+ classNames,
36
+ title,
37
+ value,
38
+ actions,
39
+ orientation,
40
+ info,
41
+ spacing,
42
+ ...rest
43
+ } = props;
34
44
  const isValueString = typeof value === "string" || !value;
35
45
  const hasActions = !!actions;
36
46
  const styles = (0, import_theme.sectionRow)({
37
- hasActions
47
+ hasActions,
48
+ orientation,
49
+ spacing
38
50
  });
39
51
  return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(
40
52
  "div",
@@ -44,7 +56,10 @@ var SectionRow = (props) => {
44
56
  }),
45
57
  ...rest,
46
58
  children: [
47
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", { className: styles.title({ className: classNames == null ? void 0 : classNames.title }), children: title }),
59
+ /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", { className: styles.title({ className: classNames == null ? void 0 : classNames.title }), children: [
60
+ title,
61
+ info && /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", { className: styles.infoTip({ className: classNames == null ? void 0 : classNames.infoTip }), children: info })
62
+ ] }),
48
63
  /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(
49
64
  "div",
50
65
  {
package/dist/index.mjs CHANGED
@@ -1,7 +1,7 @@
1
1
  "use client";
2
2
  import {
3
3
  SectionRow
4
- } from "./chunk-RAGLADU5.mjs";
4
+ } from "./chunk-SCQGARJA.mjs";
5
5
  export {
6
6
  SectionRow
7
7
  };
@@ -1,8 +1,8 @@
1
1
  import * as react_jsx_runtime from 'react/jsx-runtime';
2
- import { SlotsToClasses, SectionRowSlots } from '@kopexa/theme';
2
+ import { SectionRowVariantProps, SlotsToClasses, SectionRowSlots } from '@kopexa/theme';
3
3
  import { ComponentProps, ReactNode } from 'react';
4
4
 
5
- type SectionRowProps = Omit<ComponentProps<"div">, "children"> & {
5
+ type SectionRowProps = Omit<ComponentProps<"div">, "children"> & SectionRowVariantProps & {
6
6
  classNames?: SlotsToClasses<SectionRowSlots>;
7
7
  /**
8
8
  * The title of the section row.
@@ -1,8 +1,8 @@
1
1
  import * as react_jsx_runtime from 'react/jsx-runtime';
2
- import { SlotsToClasses, SectionRowSlots } from '@kopexa/theme';
2
+ import { SectionRowVariantProps, SlotsToClasses, SectionRowSlots } from '@kopexa/theme';
3
3
  import { ComponentProps, ReactNode } from 'react';
4
4
 
5
- type SectionRowProps = Omit<ComponentProps<"div">, "children"> & {
5
+ type SectionRowProps = Omit<ComponentProps<"div">, "children"> & SectionRowVariantProps & {
6
6
  classNames?: SlotsToClasses<SectionRowSlots>;
7
7
  /**
8
8
  * The title of the section row.
@@ -28,11 +28,23 @@ var import_shared_utils = require("@kopexa/shared-utils");
28
28
  var import_theme = require("@kopexa/theme");
29
29
  var import_jsx_runtime = require("react/jsx-runtime");
30
30
  var SectionRow = (props) => {
31
- const { className, classNames, title, value, actions, info, ...rest } = props;
31
+ const {
32
+ className,
33
+ classNames,
34
+ title,
35
+ value,
36
+ actions,
37
+ orientation,
38
+ info,
39
+ spacing,
40
+ ...rest
41
+ } = props;
32
42
  const isValueString = typeof value === "string" || !value;
33
43
  const hasActions = !!actions;
34
44
  const styles = (0, import_theme.sectionRow)({
35
- hasActions
45
+ hasActions,
46
+ orientation,
47
+ spacing
36
48
  });
37
49
  return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(
38
50
  "div",
@@ -42,7 +54,10 @@ var SectionRow = (props) => {
42
54
  }),
43
55
  ...rest,
44
56
  children: [
45
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", { className: styles.title({ className: classNames == null ? void 0 : classNames.title }), children: title }),
57
+ /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", { className: styles.title({ className: classNames == null ? void 0 : classNames.title }), children: [
58
+ title,
59
+ info && /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", { className: styles.infoTip({ className: classNames == null ? void 0 : classNames.infoTip }), children: info })
60
+ ] }),
46
61
  /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(
47
62
  "div",
48
63
  {
@@ -1,7 +1,7 @@
1
1
  "use client";
2
2
  import {
3
3
  SectionRow
4
- } from "./chunk-RAGLADU5.mjs";
4
+ } from "./chunk-SCQGARJA.mjs";
5
5
  export {
6
6
  SectionRow
7
7
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kopexa/section-row",
3
- "version": "0.0.3",
3
+ "version": "0.0.5",
4
4
  "description": "",
5
5
  "keywords": [
6
6
  "section-row"
@@ -28,7 +28,7 @@
28
28
  "react": ">=19.0.0-rc.0",
29
29
  "react-dom": ">=19.0.0-rc.0",
30
30
  "motion": ">=12.23.6",
31
- "@kopexa/theme": "1.6.3"
31
+ "@kopexa/theme": "1.6.5"
32
32
  },
33
33
  "dependencies": {
34
34
  "@kopexa/shared-utils": "1.1.5",