@dloizides/ui-nav 1.26.0 → 1.26.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/CHANGELOG.md CHANGED
@@ -1,5 +1,13 @@
1
1
  # Changelog
2
2
 
3
+ ## 1.26.2
4
+
5
+ - KEFI-LAUNCH-1 "Do every open Kefi task before the public launch": a long account name no longer overlaps the `Topbar` center slot at 360 px. The center slot keeps its content width (`flexShrink: 0`); only the account name gives way. The overlap dates from 1.24.0, when the slot was added.
6
+
7
+ ## 1.26.1
8
+
9
+ - KEFI-LAUNCH-1 "Do every open Kefi task before the public launch": the `Topbar` left slot no longer wraps beside a long account name at 360 px. The left slot keeps its width (`flexShrink: 0`) and the account name truncates to one line.
10
+
3
11
  ## 1.25.0
4
12
 
5
13
  - `PillNav` / `PillNavMenu` get an optional `menuHeading`: a visible, non-focusable heading at the top of the open `Menu` that also names it (needs `@dloizides/ui-layout` >= 1.30.0) (KEFI-EDITOR-HEADER-1 "Compact the landing editor header").
package/dist/index.d.mts CHANGED
@@ -1356,7 +1356,8 @@ declare const navStyles: {
1356
1356
  justifyContent: "space-between";
1357
1357
  };
1358
1358
  topbarLeft: {
1359
- flex: number;
1359
+ flexGrow: number;
1360
+ flexShrink: number;
1360
1361
  };
1361
1362
  topbarCenter: {
1362
1363
  flexShrink: number;
@@ -1368,6 +1369,8 @@ declare const navStyles: {
1368
1369
  topbarRight: {
1369
1370
  flexDirection: "row";
1370
1371
  alignItems: "center";
1372
+ flexShrink: number;
1373
+ minWidth: number;
1371
1374
  };
1372
1375
  topbarRowItem: {
1373
1376
  marginHorizontal: number;
@@ -1382,11 +1385,16 @@ declare const navStyles: {
1382
1385
  userBlock: {
1383
1386
  marginHorizontal: number;
1384
1387
  alignItems: "flex-end";
1388
+ flexShrink: number;
1389
+ minWidth: number;
1385
1390
  };
1386
1391
  userName: {
1387
1392
  fontWeight: "600";
1393
+ maxWidth: "100%";
1388
1394
  };
1389
1395
  accountNameBtn: {
1396
+ flexShrink: number;
1397
+ maxWidth: "100%";
1390
1398
  minHeight: number;
1391
1399
  minWidth: number;
1392
1400
  justifyContent: "center";
package/dist/index.d.ts CHANGED
@@ -1356,7 +1356,8 @@ declare const navStyles: {
1356
1356
  justifyContent: "space-between";
1357
1357
  };
1358
1358
  topbarLeft: {
1359
- flex: number;
1359
+ flexGrow: number;
1360
+ flexShrink: number;
1360
1361
  };
1361
1362
  topbarCenter: {
1362
1363
  flexShrink: number;
@@ -1368,6 +1369,8 @@ declare const navStyles: {
1368
1369
  topbarRight: {
1369
1370
  flexDirection: "row";
1370
1371
  alignItems: "center";
1372
+ flexShrink: number;
1373
+ minWidth: number;
1371
1374
  };
1372
1375
  topbarRowItem: {
1373
1376
  marginHorizontal: number;
@@ -1382,11 +1385,16 @@ declare const navStyles: {
1382
1385
  userBlock: {
1383
1386
  marginHorizontal: number;
1384
1387
  alignItems: "flex-end";
1388
+ flexShrink: number;
1389
+ minWidth: number;
1385
1390
  };
1386
1391
  userName: {
1387
1392
  fontWeight: "600";
1393
+ maxWidth: "100%";
1388
1394
  };
1389
1395
  accountNameBtn: {
1396
+ flexShrink: number;
1397
+ maxWidth: "100%";
1390
1398
  minHeight: number;
1391
1399
  minWidth: number;
1392
1400
  justifyContent: "center";
package/dist/index.js CHANGED
@@ -70,9 +70,9 @@ var navStyles = reactNative.StyleSheet.create({
70
70
  alignItems: "center",
71
71
  justifyContent: "space-between"
72
72
  },
73
- topbarLeft: { flex: 1 },
74
- topbarCenter: { flexShrink: 1, minWidth: 0, flexDirection: "row", alignItems: "center", marginHorizontal: 8 },
75
- topbarRight: { flexDirection: "row", alignItems: "center" },
73
+ topbarLeft: { flexGrow: 1, flexShrink: 0 },
74
+ topbarCenter: { flexShrink: 0, minWidth: 0, flexDirection: "row", alignItems: "center", marginHorizontal: 8 },
75
+ topbarRight: { flexDirection: "row", alignItems: "center", flexShrink: 1, minWidth: 0 },
76
76
  topbarRowItem: {
77
77
  marginHorizontal: 8,
78
78
  alignItems: "center",
@@ -81,14 +81,9 @@ var navStyles = reactNative.StyleSheet.create({
81
81
  minWidth: MIN_TOUCH_TARGET
82
82
  },
83
83
  topbarLabel: { fontSize: 14 },
84
- userBlock: { marginHorizontal: 12, alignItems: "flex-end" },
85
- userName: { fontWeight: "600" },
86
- accountNameBtn: {
87
- minHeight: MIN_TOUCH_TARGET,
88
- minWidth: MIN_TOUCH_TARGET,
89
- justifyContent: "center",
90
- alignItems: "flex-end"
91
- },
84
+ userBlock: { marginHorizontal: 12, alignItems: "flex-end", flexShrink: 1, minWidth: 0 },
85
+ userName: { fontWeight: "600", maxWidth: "100%" },
86
+ accountNameBtn: { flexShrink: 1, maxWidth: "100%", minHeight: MIN_TOUCH_TARGET, minWidth: MIN_TOUCH_TARGET, justifyContent: "center", alignItems: "flex-end" },
92
87
  userEmail: { fontSize: 12 },
93
88
  accountBtn: {
94
89
  marginLeft: 8,
@@ -1001,9 +996,9 @@ var Topbar = ({
1001
996
  style: navStyles.accountNameBtn,
1002
997
  testID: richAccount.accountTestID ?? NAV_TEST_IDS.accountName,
1003
998
  onPress: richAccount.onAccount,
1004
- children: /* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [navStyles.userName, { color: colors.text }], children: richAccount.displayName })
999
+ children: /* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { numberOfLines: 1, style: [navStyles.userName, { color: colors.text }], children: richAccount.displayName })
1005
1000
  }
1006
- ) : /* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [navStyles.userName, { color: colors.text }], testID: NAV_TEST_IDS.accountName, children: richAccount.displayName }),
1001
+ ) : /* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { numberOfLines: 1, style: [navStyles.userName, { color: colors.text }], testID: NAV_TEST_IDS.accountName, children: richAccount.displayName }),
1007
1002
  richAccount.tenantName !== void 0 ? /* @__PURE__ */ jsxRuntime.jsx(
1008
1003
  reactNative.Text,
1009
1004
  {