@titan-design/react-ui 0.9.0 → 0.9.2
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.d.mts +13 -3
- package/dist/index.d.ts +13 -3
- package/dist/index.js +20 -21
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +20 -21
- package/dist/index.mjs.map +1 -1
- package/dist/pages.js +2 -1
- package/dist/pages.js.map +1 -1
- package/dist/pages.mjs +2 -1
- package/dist/pages.mjs.map +1 -1
- package/package.json +2 -1
- package/src/components/custom/Workout/ExerciseHeading.tsx +5 -3
- package/src/components/custom/Workout/SessionHeader.tsx +6 -5
- package/src/components/custom/Workout/SessionRail.tsx +18 -7
- package/src/components/custom/Workout/SetsRepsLoad.tsx +2 -1
- package/src/components/shell/DashboardShell.tsx +7 -9
- package/src/components/shell/NavItem.tsx +6 -1
- package/src/test/no-device-internals.test.ts +51 -0
- package/src/lab/north-star/LivePage.tsx +0 -101
- package/src/lab/north-star/LiveView.tsx +0 -409
- package/src/lab/north-star/LiveWallDashboard.stories.tsx +0 -129
- package/src/lab/north-star/RestView.tsx +0 -140
- package/src/lab/north-star/fixtures.ts +0 -224
package/dist/index.mjs
CHANGED
|
@@ -10423,7 +10423,8 @@ function ExerciseIndicator({ kind, onPress, className, ...props }) {
|
|
|
10423
10423
|
return chip;
|
|
10424
10424
|
}
|
|
10425
10425
|
function headingLabel(name, sets, reps, load, unit) {
|
|
10426
|
-
|
|
10426
|
+
const loadLabel = typeof load === "number" ? roundWeight(load) : load;
|
|
10427
|
+
return `${name}, ${sets}\xD7${reps} @ ${loadLabel} ${unit}`;
|
|
10427
10428
|
}
|
|
10428
10429
|
function ExerciseHeading({
|
|
10429
10430
|
name,
|
|
@@ -10858,7 +10859,7 @@ function ExerciseCard({
|
|
|
10858
10859
|
return isExpanded ? /* @__PURE__ */ jsx(ExpandedCard, { ...rest, onToggle }) : /* @__PURE__ */ jsx(CollapsedCard, { ...rest, onToggle });
|
|
10859
10860
|
}
|
|
10860
10861
|
var t9 = getSemanticColors("dark");
|
|
10861
|
-
var
|
|
10862
|
+
var HEADER_BG = t9["background-base"];
|
|
10862
10863
|
var BAR_HEIGHT = 9;
|
|
10863
10864
|
var BAR_GAP = 3;
|
|
10864
10865
|
function SessionHeader({
|
|
@@ -10886,7 +10887,7 @@ function SessionHeader({
|
|
|
10886
10887
|
className,
|
|
10887
10888
|
style: [
|
|
10888
10889
|
{
|
|
10889
|
-
backgroundColor:
|
|
10890
|
+
backgroundColor: HEADER_BG,
|
|
10890
10891
|
paddingTop: 11,
|
|
10891
10892
|
paddingRight: 12,
|
|
10892
10893
|
paddingBottom: 12,
|
|
@@ -10963,8 +10964,8 @@ function SessionHeader({
|
|
|
10963
10964
|
}
|
|
10964
10965
|
);
|
|
10965
10966
|
}
|
|
10966
|
-
var INSET = primitiveColors.charcoal[
|
|
10967
|
-
var DIVIDER = primitiveColors.charcoal[
|
|
10967
|
+
var INSET = primitiveColors.charcoal[600];
|
|
10968
|
+
var DIVIDER = primitiveColors.charcoal[300];
|
|
10968
10969
|
var DEFAULT_WIDTH = 246;
|
|
10969
10970
|
function SessionRail({
|
|
10970
10971
|
title,
|
|
@@ -10994,7 +10995,7 @@ function SessionRail({
|
|
|
10994
10995
|
SessionHeader,
|
|
10995
10996
|
{
|
|
10996
10997
|
title,
|
|
10997
|
-
plan: exercises.map((ex) => ({ name: ex.name, sets: ex.summary.sets })),
|
|
10998
|
+
plan: exercises.map((ex) => ({ name: ex.name, sets: ex.plannedSets ?? ex.summary.sets })),
|
|
10998
10999
|
setsDone,
|
|
10999
11000
|
elapsedMs,
|
|
11000
11001
|
budgetMs,
|
|
@@ -14377,7 +14378,8 @@ function NavItem({
|
|
|
14377
14378
|
{
|
|
14378
14379
|
variant: "button",
|
|
14379
14380
|
color: "inherit",
|
|
14380
|
-
|
|
14381
|
+
style: { fontSize: 8.5, lineHeight: 11 },
|
|
14382
|
+
className: cn("font-bold uppercase tracking-[0.4px]", labelColor),
|
|
14381
14383
|
children: label
|
|
14382
14384
|
}
|
|
14383
14385
|
)
|
|
@@ -14442,21 +14444,18 @@ function DashboardShell({
|
|
|
14442
14444
|
children,
|
|
14443
14445
|
className
|
|
14444
14446
|
}) {
|
|
14445
|
-
return
|
|
14446
|
-
|
|
14447
|
-
|
|
14448
|
-
|
|
14449
|
-
|
|
14450
|
-
|
|
14451
|
-
|
|
14452
|
-
|
|
14453
|
-
|
|
14454
|
-
|
|
14455
|
-
}
|
|
14456
|
-
),
|
|
14457
|
-
/* @__PURE__ */ jsx(View, { className: "flex-1", children: children ?? /* @__PURE__ */ jsx(ContentPlaceholder, {}) })
|
|
14447
|
+
return (
|
|
14448
|
+
// Column: the TopBar spans the FULL width across the top, and the SideNav sits BELOW it
|
|
14449
|
+
// in the content row (not a full-height left rail). This keeps the brand/status band
|
|
14450
|
+
// unbroken edge-to-edge and lets the nav align under it.
|
|
14451
|
+
/* @__PURE__ */ jsxs(View, { className: cn("flex-1 bg-surface-base", className), children: [
|
|
14452
|
+
/* @__PURE__ */ jsx(TopBar, { state, devices, subtitle, onSelectDevice }),
|
|
14453
|
+
/* @__PURE__ */ jsxs(View, { className: "flex-1 flex-row", children: [
|
|
14454
|
+
/* @__PURE__ */ jsx(SideNav, { activeKey, items: navItems, liveKey, onNavigate }),
|
|
14455
|
+
/* @__PURE__ */ jsx(View, { className: "flex-1", children: children ?? /* @__PURE__ */ jsx(ContentPlaceholder, {}) })
|
|
14456
|
+
] })
|
|
14458
14457
|
] })
|
|
14459
|
-
|
|
14458
|
+
);
|
|
14460
14459
|
}
|
|
14461
14460
|
|
|
14462
14461
|
// src/utils/form.ts
|