@1771technologies/lytenyte-pro 0.0.41 → 0.0.42

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/dist/index.js CHANGED
@@ -3653,16 +3653,41 @@ function HeaderCellDefault({ column, api }) {
3653
3653
  const hints = column.uiHints ?? sx.columnBase.peek().uiHints ?? {};
3654
3654
  const columnMenuOpen = sx.columnMenuActiveColumn.use();
3655
3655
  const hasControls = hints.columnMenu || hints.sortButton && isSortable;
3656
+ const rowGroup = sx.rowGroupModel.use();
3657
+ const aggModel = sx.aggModel.use();
3658
+ const agg = aggModel[column.id];
3659
+ const fn = useMemo(() => {
3660
+ return rowGroup.length > 0 && agg ? typeof agg.fn === "string" ? `(${agg.fn})` : "fn(x)" : null;
3661
+ }, [agg, rowGroup.length]);
3662
+ const subTitle = hints.subTitle;
3663
+ const stacked = hints.stacked ?? false;
3656
3664
  return /* @__PURE__ */ jsxs(
3657
3665
  "div",
3658
3666
  {
3659
3667
  className: clsx(
3660
3668
  "lng1771-header-default",
3661
- column.type === "number" && "lng1771-header-default--end-align",
3662
- column.type !== "number" && "lng1771-header-default--start-align"
3669
+ column.type === "number" && "lng1771-header-default--end-justify",
3670
+ column.type !== "number" && "lng1771-header-default--start-justify"
3663
3671
  ),
3664
3672
  children: [
3665
- /* @__PURE__ */ jsx("div", { children: column.headerName ?? column.id }),
3673
+ /* @__PURE__ */ jsxs(
3674
+ "div",
3675
+ {
3676
+ className: clsx(
3677
+ "lng1771-header-default__label",
3678
+ column.type === "number" && "lng1771-header-default__label--end-justify",
3679
+ column.type !== "number" && "lng1771-header-default__label--start-justify",
3680
+ stacked && "lng1771-header-default__label--stacked"
3681
+ ),
3682
+ children: [
3683
+ /* @__PURE__ */ jsx("div", { children: column.headerName ?? column.id }),
3684
+ /* @__PURE__ */ jsxs("div", { className: "lng1771-header-default__label-secondary", children: [
3685
+ subTitle && /* @__PURE__ */ jsx("div", { className: "lng1771-header-default__label-secondary-title", children: subTitle }),
3686
+ hints.showAggName && fn && /* @__PURE__ */ jsx("div", { className: "lng1771-header-default__label-secondary-agg", children: fn })
3687
+ ] })
3688
+ ]
3689
+ }
3690
+ ),
3666
3691
  hasControls && /* @__PURE__ */ jsxs("div", { className: "lng1771-header-default__controls", children: [
3667
3692
  isSortable && hints.sortButton && /* @__PURE__ */ jsxs(
3668
3693
  "button",
@@ -3670,6 +3695,7 @@ function HeaderCellDefault({ column, api }) {
3670
3695
  tabIndex: -1,
3671
3696
  "data-active": currentSort != null,
3672
3697
  className: clsx("lng1771-header-default__button"),
3698
+ "data-is-sort": true,
3673
3699
  onClick: () => api.columnSortCycleToNext(column),
3674
3700
  children: [
3675
3701
  currentSort === "asc" && /* @__PURE__ */ jsx(SortAscending, { width: 16, height: 16 }),
@@ -561,6 +561,7 @@ INPUT
561
561
  height: 1px;
562
562
  width: 100%;
563
563
  background-color: var(--lng1771-gray-40);
564
+ box-sizing: border-box;
564
565
  }
565
566
 
566
567
  .lng1771-menu__item,
@@ -597,6 +598,7 @@ INPUT
597
598
  display: flex;
598
599
  align-items: center;
599
600
  justify-content: space-between;
601
+ box-sizing: border-box;
600
602
  }
601
603
 
602
604
  .lng1771-menu__arrow {
@@ -627,6 +629,7 @@ INPUT
627
629
  align-items: center;
628
630
  background-color: inherit;
629
631
  text-transform: uppercase;
632
+ box-sizing: border-box;
630
633
  }
631
634
 
632
635
  .lng1771-menu__radio-item-indicator,
@@ -635,6 +638,7 @@ INPUT
635
638
  display: flex;
636
639
  align-items: center;
637
640
  justify-content: center;
641
+ box-sizing: border-box;
638
642
  }
639
643
  .lng1771-pill {
640
644
  white-space: nowrap;
@@ -1954,8 +1958,54 @@ body.lng1771-drag-on
1954
1958
  letter-spacing: 0.25px;
1955
1959
  }
1956
1960
 
1957
- .lng1771-header-default--end-align {
1961
+ .lng1771-header-default__label {
1962
+ display: flex;
1963
+ gap: 4px;
1964
+
1965
+ & span:last-child {
1966
+ font-size: 10px;
1967
+ text-transform: uppercase;
1968
+ color: var(--lng1771-primary-50);
1969
+ }
1970
+ }
1971
+
1972
+ .lng1771-header-default__label:not(
1973
+ .lng1771-header-default__label--stacked
1974
+ ).lng1771-header-default__label--end-justify {
1975
+ flex-direction: row-reverse;
1976
+ justify-content: flex-start;
1977
+ align-items: center;
1978
+ gap: 2px;
1979
+ text-align: end;
1980
+ }
1981
+
1982
+ .lng1771-header-default__label--stacked {
1983
+ flex-direction: column;
1984
+ gap: 2px;
1985
+ }
1986
+
1987
+ .lng1771-header-default__label--end-justify {
1988
+ width: 100%;
1958
1989
  justify-content: flex-end;
1990
+ align-items: flex-end;
1991
+ text-align: end;
1992
+ }
1993
+
1994
+ .lng1771-header-default__label-secondary {
1995
+ display: flex;
1996
+ align-items: center;
1997
+ gap: 2px;
1998
+ font-size: 10px;
1999
+ }
2000
+
2001
+ .lng1771-header-default--end-justify .lng1771-header-default__label-secondary {
2002
+ flex-direction: row-reverse;
2003
+ }
2004
+
2005
+ .lng1771-header-default__label-secondary-agg {
2006
+ color: var(--lng1771-primary-50);
2007
+ font-weight: 600;
2008
+ text-transform: lowercase;
1959
2009
  }
1960
2010
 
1961
2011
  .lng1771-header-default__controls {
@@ -1965,11 +2015,11 @@ body.lng1771-drag-on
1965
2015
  gap: 4px;
1966
2016
  }
1967
2017
 
1968
- .lng1771-header-default--start-align .lng1771-header-default__controls {
2018
+ .lng1771-header-default--start-justify .lng1771-header-default__controls {
1969
2019
  inset-inline-end: 12px;
1970
2020
  }
1971
2021
 
1972
- .lng1771-header-default--end-align .lng1771-header-default__controls {
2022
+ .lng1771-header-default--end-justify .lng1771-header-default__controls {
1973
2023
  inset-inline-start: 12px;
1974
2024
  flex-direction: row-reverse;
1975
2025
  }
@@ -1989,7 +2039,6 @@ body.lng1771-drag-on
1989
2039
 
1990
2040
  &:hover {
1991
2041
  background-color: var(--lng1771-gray-20);
1992
- border-color: var(--lng1771-gray-30);
1993
2042
  cursor: pointer;
1994
2043
  }
1995
2044
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@1771technologies/lytenyte-pro",
3
- "version": "0.0.41",
3
+ "version": "0.0.42",
4
4
  "license": "COMMERCIAL",
5
5
  "type": "module",
6
6
  "files": [
@@ -70,20 +70,20 @@
70
70
  "react-dom": "^18.0.0 || ^19.0.0"
71
71
  },
72
72
  "dependencies": {
73
- "@1771technologies/grid-client-data-source-pro": "0.0.41",
74
- "@1771technologies/grid-core": "0.0.41",
75
- "@1771technologies/grid-design": "0.0.41",
76
- "@1771technologies/grid-provider": "0.0.41",
77
- "@1771technologies/grid-store-pro": "0.0.41",
78
- "@1771technologies/grid-tree-data-source": "0.0.41",
79
- "@1771technologies/grid-types": "0.0.41",
80
- "@1771technologies/js-utils": "0.0.41",
81
- "@1771technologies/lytenyte-core": "0.0.41",
82
- "@1771technologies/react-cascada": "0.0.41",
83
- "@1771technologies/react-dragon": "0.0.41",
84
- "@1771technologies/react-sizer": "0.0.41",
85
- "@1771technologies/react-split-pane": "0.0.41",
86
- "@1771technologies/react-utils": "0.0.41",
73
+ "@1771technologies/grid-client-data-source-pro": "0.0.42",
74
+ "@1771technologies/grid-core": "0.0.42",
75
+ "@1771technologies/grid-design": "0.0.42",
76
+ "@1771technologies/grid-provider": "0.0.42",
77
+ "@1771technologies/grid-store-pro": "0.0.42",
78
+ "@1771technologies/grid-tree-data-source": "0.0.42",
79
+ "@1771technologies/grid-types": "0.0.42",
80
+ "@1771technologies/js-utils": "0.0.42",
81
+ "@1771technologies/lytenyte-core": "0.0.42",
82
+ "@1771technologies/react-cascada": "0.0.42",
83
+ "@1771technologies/react-dragon": "0.0.42",
84
+ "@1771technologies/react-sizer": "0.0.42",
85
+ "@1771technologies/react-split-pane": "0.0.42",
86
+ "@1771technologies/react-utils": "0.0.42",
87
87
  "@base-ui-components/react": "1.0.0-alpha.7"
88
88
  },
89
89
  "devDependencies": {