@oxy.so/bloom 4.15.0 → 4.16.1
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/docs/app-shell.mdx +74 -6
- package/docs/bottom-bar.mdx +9 -1
- package/docs/hooks.mdx +23 -0
- package/docs/sidebar.mdx +15 -2
- package/docs/tab-bar.mdx +1 -1
- package/lib/commonjs/app-shell/AppShell.js +3 -1
- package/lib/commonjs/app-shell/AppShell.js.map +1 -1
- package/lib/commonjs/app-shell/AppShellEngine.js +54 -28
- package/lib/commonjs/app-shell/AppShellEngine.js.map +1 -1
- package/lib/commonjs/app-shell/AppShellHeader.js +4 -3
- package/lib/commonjs/app-shell/AppShellHeader.js.map +1 -1
- package/lib/commonjs/app-shell/NotificationBell.js +8 -4
- package/lib/commonjs/app-shell/NotificationBell.js.map +1 -1
- package/lib/commonjs/app-shell/ProOfferCard.js +19 -11
- package/lib/commonjs/app-shell/ProOfferCard.js.map +1 -1
- package/lib/commonjs/bottom-bar/BottomBarBase.js +9 -2
- package/lib/commonjs/bottom-bar/BottomBarBase.js.map +1 -1
- package/lib/commonjs/hooks/index.js +7 -0
- package/lib/commonjs/hooks/index.js.map +1 -1
- package/lib/commonjs/hooks/use-is-rtl.js +104 -0
- package/lib/commonjs/hooks/use-is-rtl.js.map +1 -0
- package/lib/commonjs/sidebar/Sidebar.js +41 -22
- package/lib/commonjs/sidebar/Sidebar.js.map +1 -1
- package/lib/commonjs/sidebar/SidebarFolder.js +11 -5
- package/lib/commonjs/sidebar/SidebarFolder.js.map +1 -1
- package/lib/commonjs/sidebar/SidebarLogoView.js +2 -2
- package/lib/commonjs/sidebar/SidebarLogoView.js.map +1 -1
- package/lib/commonjs/sidebar/SidebarModeSwitcher.js +1 -1
- package/lib/commonjs/sidebar/SidebarModeSwitcher.js.map +1 -1
- package/lib/commonjs/sidebar/SidebarPlanCard.js +3 -3
- package/lib/commonjs/sidebar/SidebarPlanCard.js.map +1 -1
- package/lib/commonjs/sidebar/SidebarRail.js +7 -1
- package/lib/commonjs/sidebar/SidebarRail.js.map +1 -1
- package/lib/commonjs/sidebar/SidebarRailItem.js +2 -2
- package/lib/commonjs/sidebar/SidebarRailItem.js.map +1 -1
- package/lib/commonjs/sidebar/SidebarTeamMenu.js +12 -7
- package/lib/commonjs/sidebar/SidebarTeamMenu.js.map +1 -1
- package/lib/commonjs/sidebar/SidebarUserMenu.js +9 -5
- package/lib/commonjs/sidebar/SidebarUserMenu.js.map +1 -1
- package/lib/commonjs/tab-bar/TabBarBase.js +57 -21
- package/lib/commonjs/tab-bar/TabBarBase.js.map +1 -1
- package/lib/module/app-shell/AppShell.js +3 -1
- package/lib/module/app-shell/AppShell.js.map +1 -1
- package/lib/module/app-shell/AppShellEngine.js +54 -28
- package/lib/module/app-shell/AppShellEngine.js.map +1 -1
- package/lib/module/app-shell/AppShellHeader.js +4 -3
- package/lib/module/app-shell/AppShellHeader.js.map +1 -1
- package/lib/module/app-shell/NotificationBell.js +8 -4
- package/lib/module/app-shell/NotificationBell.js.map +1 -1
- package/lib/module/app-shell/ProOfferCard.js +19 -11
- package/lib/module/app-shell/ProOfferCard.js.map +1 -1
- package/lib/module/bottom-bar/BottomBarBase.js +9 -2
- package/lib/module/bottom-bar/BottomBarBase.js.map +1 -1
- package/lib/module/hooks/index.js +1 -0
- package/lib/module/hooks/index.js.map +1 -1
- package/lib/module/hooks/use-is-rtl.js +97 -0
- package/lib/module/hooks/use-is-rtl.js.map +1 -0
- package/lib/module/sidebar/Sidebar.js +41 -22
- package/lib/module/sidebar/Sidebar.js.map +1 -1
- package/lib/module/sidebar/SidebarFolder.js +11 -5
- package/lib/module/sidebar/SidebarFolder.js.map +1 -1
- package/lib/module/sidebar/SidebarLogoView.js +2 -2
- package/lib/module/sidebar/SidebarLogoView.js.map +1 -1
- package/lib/module/sidebar/SidebarModeSwitcher.js +1 -1
- package/lib/module/sidebar/SidebarModeSwitcher.js.map +1 -1
- package/lib/module/sidebar/SidebarPlanCard.js +3 -3
- package/lib/module/sidebar/SidebarPlanCard.js.map +1 -1
- package/lib/module/sidebar/SidebarRail.js +7 -1
- package/lib/module/sidebar/SidebarRail.js.map +1 -1
- package/lib/module/sidebar/SidebarRailItem.js +2 -2
- package/lib/module/sidebar/SidebarRailItem.js.map +1 -1
- package/lib/module/sidebar/SidebarTeamMenu.js +12 -7
- package/lib/module/sidebar/SidebarTeamMenu.js.map +1 -1
- package/lib/module/sidebar/SidebarUserMenu.js +9 -5
- package/lib/module/sidebar/SidebarUserMenu.js.map +1 -1
- package/lib/module/tab-bar/TabBarBase.js +57 -21
- package/lib/module/tab-bar/TabBarBase.js.map +1 -1
- package/lib/typescript/commonjs/app-shell/AppShellEngine.d.ts.map +1 -1
- package/lib/typescript/commonjs/app-shell/AppShellHeader.d.ts.map +1 -1
- package/lib/typescript/commonjs/app-shell/NotificationBell.d.ts.map +1 -1
- package/lib/typescript/commonjs/app-shell/ProOfferCard.d.ts.map +1 -1
- package/lib/typescript/commonjs/app-shell/types.d.ts +16 -5
- package/lib/typescript/commonjs/app-shell/types.d.ts.map +1 -1
- package/lib/typescript/commonjs/bottom-bar/BottomBarBase.d.ts.map +1 -1
- package/lib/typescript/commonjs/hooks/index.d.ts +1 -0
- package/lib/typescript/commonjs/hooks/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/hooks/use-is-rtl.d.ts +53 -0
- package/lib/typescript/commonjs/hooks/use-is-rtl.d.ts.map +1 -0
- package/lib/typescript/commonjs/icons/shared.d.ts +10 -10
- package/lib/typescript/commonjs/sidebar/Sidebar.d.ts.map +1 -1
- package/lib/typescript/commonjs/sidebar/SidebarFolder.d.ts.map +1 -1
- package/lib/typescript/commonjs/sidebar/SidebarRail.d.ts +1 -1
- package/lib/typescript/commonjs/sidebar/SidebarRail.d.ts.map +1 -1
- package/lib/typescript/commonjs/sidebar/SidebarTeamMenu.d.ts.map +1 -1
- package/lib/typescript/commonjs/sidebar/SidebarUserMenu.d.ts.map +1 -1
- package/lib/typescript/commonjs/sidebar/types.d.ts +24 -3
- package/lib/typescript/commonjs/sidebar/types.d.ts.map +1 -1
- package/lib/typescript/commonjs/tab-bar/TabBarBase.d.ts.map +1 -1
- package/lib/typescript/module/app-shell/AppShellEngine.d.ts.map +1 -1
- package/lib/typescript/module/app-shell/AppShellHeader.d.ts.map +1 -1
- package/lib/typescript/module/app-shell/NotificationBell.d.ts.map +1 -1
- package/lib/typescript/module/app-shell/ProOfferCard.d.ts.map +1 -1
- package/lib/typescript/module/app-shell/types.d.ts +16 -5
- package/lib/typescript/module/app-shell/types.d.ts.map +1 -1
- package/lib/typescript/module/bottom-bar/BottomBarBase.d.ts.map +1 -1
- package/lib/typescript/module/hooks/index.d.ts +1 -0
- package/lib/typescript/module/hooks/index.d.ts.map +1 -1
- package/lib/typescript/module/hooks/use-is-rtl.d.ts +53 -0
- package/lib/typescript/module/hooks/use-is-rtl.d.ts.map +1 -0
- package/lib/typescript/module/icons/shared.d.ts +10 -10
- package/lib/typescript/module/sidebar/Sidebar.d.ts.map +1 -1
- package/lib/typescript/module/sidebar/SidebarFolder.d.ts.map +1 -1
- package/lib/typescript/module/sidebar/SidebarRail.d.ts +1 -1
- package/lib/typescript/module/sidebar/SidebarRail.d.ts.map +1 -1
- package/lib/typescript/module/sidebar/SidebarTeamMenu.d.ts.map +1 -1
- package/lib/typescript/module/sidebar/SidebarUserMenu.d.ts.map +1 -1
- package/lib/typescript/module/sidebar/types.d.ts +24 -3
- package/lib/typescript/module/sidebar/types.d.ts.map +1 -1
- package/lib/typescript/module/tab-bar/TabBarBase.d.ts.map +1 -1
- package/package.json +1 -1
- package/src/app-shell/AppShell.tsx +1 -1
- package/src/app-shell/AppShellEngine.tsx +45 -24
- package/src/app-shell/AppShellHeader.tsx +4 -3
- package/src/app-shell/NotificationBell.tsx +8 -4
- package/src/app-shell/ProOfferCard.tsx +18 -10
- package/src/app-shell/types.ts +16 -5
- package/src/bottom-bar/BottomBarBase.tsx +9 -3
- package/src/hooks/index.ts +1 -0
- package/src/hooks/use-is-rtl.ts +102 -0
- package/src/sidebar/Sidebar.tsx +41 -21
- package/src/sidebar/SidebarFolder.tsx +7 -4
- package/src/sidebar/SidebarLogoView.tsx +2 -2
- package/src/sidebar/SidebarModeSwitcher.tsx +1 -1
- package/src/sidebar/SidebarPlanCard.tsx +3 -3
- package/src/sidebar/SidebarRail.tsx +7 -1
- package/src/sidebar/SidebarRailItem.tsx +2 -2
- package/src/sidebar/SidebarTeamMenu.tsx +10 -6
- package/src/sidebar/SidebarUserMenu.tsx +8 -5
- package/src/sidebar/types.ts +25 -3
- package/src/tab-bar/TabBarBase.tsx +58 -21
package/docs/app-shell.mdx
CHANGED
|
@@ -324,7 +324,7 @@ overlapping another, and no console error.
|
|
|
324
324
|
- `lg` and up: the rail sits in flow; the content column is centred, max `contentMaxWidth` (1300), header then content 16 apart.
|
|
325
325
|
- Below `lg` the header shows a menu button, and `drawer` picks how the rail arrives:
|
|
326
326
|
- `overlay` — a drawer over the page on a 40% black backdrop (portaled through `OverlayRoot`, so it ranks with every other overlay).
|
|
327
|
-
- `reveal` — the rail waits flat beneath the page; the page slides 272 right and rounds to 32 while the rail scales in from 0.94 (325ms). Pressing the page closes it.
|
|
327
|
+
- `reveal` — the rail waits flat beneath the page; the page slides 272 toward the end edge (right in LTR, left in RTL) and rounds to 32 while the rail scales in from 0.94 (325ms). Pressing the page closes it.
|
|
328
328
|
- `drawerOpen` / `onDrawerOpenChange` control it.
|
|
329
329
|
- `sidebar={{ variant: 'rail', … }}` keeps the 80px navigation rail in flow from `sm` instead of `lg`; below `sm` the menu button opens the drawer, which always shows the full panel.
|
|
330
330
|
|
|
@@ -336,7 +336,7 @@ overlapping another, and no console error.
|
|
|
336
336
|
</AppShell>
|
|
337
337
|
```
|
|
338
338
|
|
|
339
|
-
A second column
|
|
339
|
+
A second column at the end edge of the page — the right in LTR, the left in RTL (`dashboard` and `feed`; `split` has
|
|
340
340
|
its `info` pane instead and `focus` has no second column at all). From `asideFrom` (`xl`, 1280; or `md` / `lg`) it sits beside the content at `asideWidth` (320), pinned like the sidebar — with document scroll it stays in natural document flow. A tall aside scrolls with the page until its lower edge is visible, then sticks; it does not capture wheel gestures in a nested ScrollView. Container and fixed modes retain bounded aside scrolling. Below the breakpoint it is stacked after the content (`asideCollapse="stack"`, the default) or dropped (`"hidden"`). Under `drawer="reveal"` it slides with the page.
|
|
341
341
|
|
|
342
342
|
## Eight shells, one component
|
|
@@ -387,7 +387,7 @@ render three of these side by side with nothing positioned by hand.
|
|
|
387
387
|
<AppShell sidebar={{ items }} /> {/* the floating card */}
|
|
388
388
|
```
|
|
389
389
|
|
|
390
|
-
A `docked` nav is flush to the window: the shell drops its left and vertical padding around that column, gives up the column gap and lets the nav run the full height, because the nav's own hairline is the separator. Everything else about the shell is unchanged. The surfaces and sizes themselves are in [`Sidebar`](/docs/bloom/main/sidebar).
|
|
390
|
+
A `docked` nav is flush to the window: the shell drops its start (left in LTR) and vertical padding around that column, gives up the column gap and lets the nav run the full height, because the nav's own hairline is the separator. Everything else about the shell is unchanged. The surfaces and sizes themselves are in [`Sidebar`](/docs/bloom/main/sidebar).
|
|
391
391
|
|
|
392
392
|
## Opening the drawer without a title
|
|
393
393
|
|
|
@@ -463,13 +463,81 @@ never the arrangement:
|
|
|
463
463
|
None of this is exercised by the web gate: jest resolves no platform extensions
|
|
464
464
|
here, and Storybook is react-native-web. It is reasoned, not measured.
|
|
465
465
|
|
|
466
|
+
## Right-to-left
|
|
467
|
+
|
|
468
|
+
`AppShell`, `Sidebar`, `BottomBar` and the tab bar under it mirror for
|
|
469
|
+
right-to-left languages. Bloom never decides the direction — it reads the one
|
|
470
|
+
the platform's layout engine is already using:
|
|
471
|
+
|
|
472
|
+
- **Web:** `document.documentElement.dir`. Set `<html dir="rtl">` (and `lang`)
|
|
473
|
+
when the locale is Arabic, Hebrew, Persian or Urdu; change it at runtime and
|
|
474
|
+
the shell follows on the next frame, no reload.
|
|
475
|
+
- **Native:** `I18nManager.isRTL`. Call `I18nManager.allowRTL(true)` and
|
|
476
|
+
`I18nManager.forceRTL(true)` for an RTL locale; React Native applies it on
|
|
477
|
+
the NEXT launch, so reload the app (e.g. `expo-updates`' `reloadAsync`) after
|
|
478
|
+
changing it. A running app cannot mirror itself.
|
|
479
|
+
|
|
480
|
+
That is all a consumer does. Inside, two mechanisms:
|
|
481
|
+
|
|
482
|
+
- **Insets are logical.** The drawer rail, the overlay drawer, the docked
|
|
483
|
+
hairline, the aside's padding, the notification count, the offer card and the
|
|
484
|
+
bottom bar's action use `insetInlineStart`/`paddingInlineEnd`/`borderEndWidth`
|
|
485
|
+
and friends. Yoga resolves them against `I18nManager`. react-native-web does
|
|
486
|
+
NOT resolve them against `<html dir>`: its inline and atomic style paths
|
|
487
|
+
rewrite them to PHYSICAL properties against its own direction context — a
|
|
488
|
+
`dir` prop on an ancestor `View` — defaulting to left-to-right (measured on
|
|
489
|
+
0.21.2: `insetInlineStart: 0` renders `left: 0px` with no context). So each
|
|
490
|
+
family root (`AppShell`, the portaled drawer, `Sidebar`, the rail,
|
|
491
|
+
`BottomBar`, the tab bar, `ProOfferCard`, `NotificationBell`) spreads
|
|
492
|
+
`dir="rtl"` on web when the document is right-to-left. A screen of your own
|
|
493
|
+
that uses logical insets outside those roots needs the same:
|
|
494
|
+
`<View dir={useIsRtl() ? 'rtl' : undefined}>` on web.
|
|
495
|
+
- **The CSS spelling, not React Native's.** `paddingInlineStart`, never
|
|
496
|
+
`paddingStart`: reanimated's web writer hands a mapper's result to
|
|
497
|
+
react-native-web's `createReactDOMStyle`, which does not rewrite
|
|
498
|
+
`paddingStart`, so the browser would drop it inside an animated style. The
|
|
499
|
+
CSS spelling passes through as a real logical property (and Fabric parses it
|
|
500
|
+
on native).
|
|
501
|
+
- **Signs read `useIsRtl()`** (`@oxy.so/bloom/hooks`): the `reveal` slide, the
|
|
502
|
+
rail's `transformOrigin`, the sidebar's collapse control and glyph, the
|
|
503
|
+
folder connector, the offer card's shimmer, the tab bar's highlight and scrub
|
|
504
|
+
hit-testing, and the account/team menus' floating `side`/`align` (floating
|
|
505
|
+
sides are physical).
|
|
506
|
+
|
|
507
|
+
`src/__tests__/app-shell-rtl-census.test.ts` fails the build on a new one-sided
|
|
508
|
+
physical key, a React Native logical key, or a sign without `useIsRtl` in these
|
|
509
|
+
families. Jest has no layout engine, so the mirrored PAINT is verified in a
|
|
510
|
+
browser with `dir="rtl"` and on a device with `forceRTL` — not by the suite.
|
|
511
|
+
|
|
512
|
+
## Labels
|
|
513
|
+
|
|
514
|
+
Every word the shell and the sidebar speak is a prop defaulting to the English
|
|
515
|
+
it replaced, so an app can translate them:
|
|
516
|
+
|
|
517
|
+
| Prop | Default | Names |
|
|
518
|
+
| --- | --- | --- |
|
|
519
|
+
| `drawerOpenLabel` | `"Open navigation"` | the header's hamburger (also `AppShellHeader` `menuLabel`, `AppShellMenuButton` `accessibilityLabel`) |
|
|
520
|
+
| `drawerCloseLabel` | `"Close navigation"` | the overlay drawer's backdrop and the `reveal` page veil |
|
|
521
|
+
| `resizeLabel` | `"Resize panes"` | the `split` divider |
|
|
522
|
+
| `sidebar.accessibilityLabel` | `"Sidebar"` | the navigation landmark (panel and rail) |
|
|
523
|
+
| `sidebar.collapseLabel` / `expandLabel` | `"Collapse sidebar"` / `"Expand sidebar"` | the collapse control, per state |
|
|
524
|
+
| `sidebar.closeLabel` | `"Close sidebar"` | the drawer sidebar's own close button |
|
|
525
|
+
| `sidebar.searchLabel` / `searchButtonLabel` | `"Quick Search"` / `"Search"` | the search button (panel / flat mobile header) |
|
|
526
|
+
| `sidebar.filterLabel` / `clearSearchLabel` | `"Filter navigation"` / `"Clear navigation search"` | the search field and its clear button |
|
|
527
|
+
| `sidebar.account.menuLabel` / `team.menuLabel` | `"Account menu"` / `` `${name} menu` `` | the switcher menus |
|
|
528
|
+
|
|
529
|
+
`NotificationBell` (`accessibilityLabel`), `ProOfferCard` (`accessibilityLabel`,
|
|
530
|
+
`dismissLabel`) and the sidebar's `searchPlaceholder`, `noResultsLabel`,
|
|
531
|
+
`modesLabel`, `account.usersLabel`/`addUserLabel`/`manageLabel` and
|
|
532
|
+
`plan.actionLabel` were already props.
|
|
533
|
+
|
|
466
534
|
## NotificationBell
|
|
467
535
|
|
|
468
|
-
A medium secondary icon button with the unread count (16px red disc, 1.5px ring in the button's surface that drops on hover) and a `NotificationCenter` in a
|
|
536
|
+
A medium secondary icon button with the unread count (16px red disc, 1.5px ring in the button's surface that drops on hover) and a `NotificationCenter` in a popover below it aligned to its trailing edge (mirrored under RTL), 440 wide. `unreadCount` overrides the computed count.
|
|
469
537
|
|
|
470
538
|
## ProOfferCard
|
|
471
539
|
|
|
472
|
-
280 wide, 12 from the bottom-left (`placement="inline"` renders in flow), radius 16, card-coloured hairline, the waitlist shadow; a light band across the top (default: an accent gradient; pass `backdrop` for your own, masked the same way on web), the copy, a full-width CTA with a sweeping shimmer (hidden under reduced motion) and an xs close button. It rises in after `enterDelay` (1.2s). Persisting the dismissal is the host's job.
|
|
540
|
+
280 wide, 12 from the bottom-start corner — bottom-left in LTR, bottom-right in RTL (`placement="inline"` renders in flow), radius 16, card-coloured hairline, the waitlist shadow; a light band across the top (default: an accent gradient; pass `backdrop` for your own, masked the same way on web), the copy, a full-width CTA with a sweeping shimmer (hidden under reduced motion) and an xs close button. It rises in after `enterDelay` (1.2s). Persisting the dismissal is the host's job.
|
|
473
541
|
|
|
474
542
|
A live ray-field WebGL backdrop and animated Pro logo are brand artwork and are not included — pass `backdrop` / `logo`.
|
|
475
543
|
|
|
@@ -485,7 +553,7 @@ Use `navigation={[{ value, label, icon }]}`, `value` and `onValueChange` once.
|
|
|
485
553
|
and sidebar from 1024. Explicit `bottom`, `rail` or `sidebar` overrides that choice.
|
|
486
554
|
|
|
487
555
|
`primaryAction` accepts Fab props. In bottom placement it appears beside the tab
|
|
488
|
-
capsule and shares its animation; wider placements float it at the bottom-right
|
|
556
|
+
capsule and shares its animation; wider placements float it at the bottom-end corner (bottom-right in LTR)
|
|
489
557
|
of the content area, independently of the sidebar.
|
|
490
558
|
`header` overrides the default header; `title`, `breadcrumb` and `actions` configure
|
|
491
559
|
that default. `contentMaxWidth` defaults to 1300. `overlay` stays in the screen's
|
package/docs/bottom-bar.mdx
CHANGED
|
@@ -32,7 +32,15 @@ available platform material. `maxWidth` defaults to 560 points.
|
|
|
32
32
|
The universal entry uses no Apple-only peers. The specialized `tab-bar` subpath
|
|
33
33
|
continues to provide its native enhancements independently.
|
|
34
34
|
|
|
35
|
-
`actionPlacement="auto"` (default) moves the action above and to the right when placing it beside the tabs would leave less than 56 points per destination. `beside` retains the horizontal arrangement; `above` always lifts it. The action uses the same scroll-driven visibility in both placements. Its measured height plus a 10-point gap joins the reserved footprint, so the final content remains reachable.
|
|
35
|
+
`actionPlacement="auto"` (default) moves the action above and to the end edge (the right in LTR, the left in RTL) when placing it beside the tabs would leave less than 56 points per destination. `beside` retains the horizontal arrangement; `above` always lifts it. The action uses the same scroll-driven visibility in both placements. Its measured height plus a 10-point gap joins the reserved footprint, so the final content remains reachable.
|
|
36
|
+
|
|
37
|
+
## Right-to-left
|
|
38
|
+
|
|
39
|
+
The row is a flex row, so under `dir="rtl"` (web) or `I18nManager.isRTL`
|
|
40
|
+
(native) the first destination sits at the right and the action at the left. The
|
|
41
|
+
tab bar's highlight and its tap/scrub hit-testing follow — both read
|
|
42
|
+
`useIsRtl()`, because a `translateX` and a physical touch `x` do not mirror by
|
|
43
|
+
themselves. Setup: [`AppShell`, Right-to-left](/docs/bloom/main/app-shell).
|
|
36
44
|
|
|
37
45
|
## Pager and shell composition
|
|
38
46
|
|
package/docs/hooks.mdx
CHANGED
|
@@ -114,6 +114,29 @@ Mount `BloomHapticsProvider` if the app needs to turn haptics off globally
|
|
|
114
114
|
Fetch an image before it is rendered — the transition into a full-screen viewer,
|
|
115
115
|
the next page of a carousel.
|
|
116
116
|
|
|
117
|
+
## `useIsRtl`
|
|
118
|
+
|
|
119
|
+
Whether the layout is mirrored, read from where each platform's layout engine
|
|
120
|
+
reads it: `<html dir>` on web (observed live, so a language switch re-renders),
|
|
121
|
+
`I18nManager.isRTL` on native (fixed for the process — `forceRTL` applies on the
|
|
122
|
+
next launch). The server snapshot is `false`.
|
|
123
|
+
|
|
124
|
+
Use it only for what a logical style key cannot express — a `translateX` or
|
|
125
|
+
`scaleX` sign, a `transformOrigin`, a floating `side`. Insets should be the
|
|
126
|
+
CSS logical keys (`paddingInlineStart`, `insetInlineEnd`), which mirror with no
|
|
127
|
+
hook; in a reanimated mapper, React Native's `paddingStart` spelling is dropped
|
|
128
|
+
on web. Capture it into a worklet as a multiplier and list it in the deps:
|
|
129
|
+
|
|
130
|
+
On web, react-native-web resolves logical insets against a `dir` prop on an
|
|
131
|
+
ancestor `View`, not against `<html dir>` — so a root that uses them also
|
|
132
|
+
needs `<View dir={useIsRtl() ? 'rtl' : undefined}>` (Bloom's page-frame
|
|
133
|
+
families do this themselves).
|
|
134
|
+
|
|
135
|
+
```tsx
|
|
136
|
+
const dir = useIsRtl() ? -1 : 1;
|
|
137
|
+
const style = useAnimatedStyle(() => ({ transform: [{ translateX: dir * 24 * p.value }] }), [p, dir]);
|
|
138
|
+
```
|
|
139
|
+
|
|
117
140
|
## `mergeRefs`
|
|
118
141
|
|
|
119
142
|
Combines several refs into one callback.
|
package/docs/sidebar.mdx
CHANGED
|
@@ -110,7 +110,7 @@ The logo leads the header beside the collapse (or close) control; `account`, if
|
|
|
110
110
|
```
|
|
111
111
|
|
|
112
112
|
- An 80px column on background-full with no panel chrome. The primary items are centred vertically in a scroller (px 8, py 24, gap 8); `secondaryItems` sit at the foot.
|
|
113
|
-
- Each item (`SidebarRailItem`) is min-height 64, radius 20, py 8: a 48 × 32 pill behind a 22px icon, and 5 below it a one-line 10px label. Selected, the pill takes the accent-500 fill with the primary foreground, the label turns text-primary medium, and `activeIcon` (e.g. the filled glyph) replaces `icon`. Hover fills the pill with background-secondary-hover. A `badge` sits over the pill's top-right
|
|
113
|
+
- Each item (`SidebarRailItem`) is min-height 64, radius 20, py 8: a 48 × 32 pill behind a 22px icon, and 5 below it a one-line 10px label. Selected, the pill takes the accent-500 fill with the primary foreground, the label turns text-primary medium, and `activeIcon` (e.g. the filled glyph) replaces `icon`. Hover fills the pill with background-secondary-hover. A `badge` sits over the pill's top-end corner (top-right in LTR).
|
|
114
114
|
- Navigation only: `account`, `team`, `plan`, `tree`, quick search, the theme toggle and collapse belong to the panel and are ignored here. Routing (`href`, `onPress`, `onNavigate`) works as below.
|
|
115
115
|
- In `AppShell` the rail stays in flow from `sm`; see `docs/app-shell.mdx`.
|
|
116
116
|
|
|
@@ -162,7 +162,20 @@ The docked edge is not the card's border: that one is white in light mode, a hig
|
|
|
162
162
|
|
|
163
163
|
The table describes a card without a primary action. Runtime collapsed width is the icon lane plus 7px padding on each side and the borders actually painted: card adds2px, docked1px, plain0px. The lane is the row square, or at least50px when `primaryAction` is present (total66/65/64px respectively). Navigation and search retain their30/40/44px circles, centred in the wider lane; their icons are not enlarged. Logo, collapse control, modes, theme and account controls share that centre. Expanded navigation retains its2px inset, and the primary action uses the same edges. A row outside a sidebar takes `size` itself; inside one it inherits the panel's.
|
|
164
164
|
|
|
165
|
-
`AppShell` passes both through (`sidebar={{ surface, size }}`) and treats `docked` as what it is — it gives up its
|
|
165
|
+
`AppShell` passes both through (`sidebar={{ surface, size }}`) and treats `docked` as what it is — it gives up its start and vertical padding around that column and lets it run the full height, so the hairline is the separator instead of a gutter.
|
|
166
|
+
|
|
167
|
+
## Right-to-left
|
|
168
|
+
|
|
169
|
+
The sidebar mirrors with the document (`<html dir="rtl">` on web,
|
|
170
|
+
`I18nManager.isRTL` on native): the `docked` hairline is on the END edge
|
|
171
|
+
(`borderEndWidth`), so it faces the content in either direction; the collapse
|
|
172
|
+
control, its glyph, the folder connector and the account/team menus flip with
|
|
173
|
+
it. How direction is read and what an app must set: [`AppShell`, Right-to-left](/docs/bloom/main/app-shell).
|
|
174
|
+
|
|
175
|
+
Every label it speaks is a prop (`accessibilityLabel`, `collapseLabel`,
|
|
176
|
+
`expandLabel`, `closeLabel`, `searchLabel`, `searchButtonLabel`, `filterLabel`,
|
|
177
|
+
`clearSearchLabel`, `noResultsLabel`, `account.menuLabel`, `team.menuLabel`);
|
|
178
|
+
defaults and what each names: [`AppShell`, Labels](/docs/bloom/main/app-shell).
|
|
166
179
|
|
|
167
180
|
## Navigation
|
|
168
181
|
|
package/docs/tab-bar.mdx
CHANGED
|
@@ -425,7 +425,7 @@ The tail gradient is derived from the theme's page background, so it works on li
|
|
|
425
425
|
| `children` | `ReactNode` | — | The `TabBarButton`s, in bar order. |
|
|
426
426
|
| `activeIndex?` | `number` | — | **Controlled path.** The focused tab; an index that names no tab (`-1`, past the last, fractional) hides the highlight — see [No selection](#no-selection). Omit it with a router — use per-button `isFocused` instead. |
|
|
427
427
|
| `activeProgress?` | `SharedValue<number>` | — | **Driven path.** The highlight's live position in tab units, on the UI thread — a pager writes its page position here and the highlight tracks the finger 1:1. Says WHERE, never WHETHER: pair it with `activeIndex` or per-button `isFocused` for selection. See [Driven by a pager](#driven-by-a-pager). |
|
|
428
|
-
| `onIndexChange?` | `(index: number) => void` | — | Called with the chosen index on tap, on scrub release, or on keyboard / assistive-technology activation. |
|
|
428
|
+
| `onIndexChange?` | `(index: number) => void` | — | Called once per activation with the chosen index: on tap, on scrub release, or on keyboard / assistive-technology activation. On web and Android the tapped button's own press stands down, because the tap gesture has already reported it. |
|
|
429
429
|
| `onIndexLongPress?` | `(index: number) => void` | — | Called with the index under the finger after a 500ms hold. Does not select. The gesture is armed only when this is supplied. |
|
|
430
430
|
| `theme?` | `Partial<TabBarTheme>` | — | Partial override of the token-resolved theme. |
|
|
431
431
|
| `haptics?` | `boolean` | `true` | Picker-style tick as the scrub crosses tab boundaries. Already a no-op on web and when `expo-haptics` is absent. |
|
|
@@ -273,7 +273,9 @@ function createAppShell(BottomBar, Fab, ...panelComponents) {
|
|
|
273
273
|
title: props.title,
|
|
274
274
|
subtitle: props.breadcrumb,
|
|
275
275
|
actions: props.actions,
|
|
276
|
-
leading: /*#__PURE__*/(0, _jsxRuntime.jsx)(_AppShellMenuButton.AppShellMenuButton, {
|
|
276
|
+
leading: /*#__PURE__*/(0, _jsxRuntime.jsx)(_AppShellMenuButton.AppShellMenuButton, {
|
|
277
|
+
accessibilityLabel: props.drawerOpenLabel
|
|
278
|
+
})
|
|
277
279
|
}) : undefined,
|
|
278
280
|
bottomBar: props.bottomBar !== undefined ? props.bottomBar : bottom,
|
|
279
281
|
bottomBarVisibility: props.bottomBarVisibility ?? 'compact',
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_react","_interopRequireWildcard","require","_reactNative","_breakpoints","_index","_index2","_useTheme","_index3","_ResponsiveNavigation","_AppShellEngine","_layout","_AppShellMenuButton","_constants","_jsxRuntime","e","t","WeakMap","r","n","__esModule","o","i","f","__proto__","default","has","get","set","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor","resolveNavigationPlacement","width","placement","BREAKPOINTS","md","lg","createAppShell","BottomBar","Fab","panelComponents","AppShellEngine","createAppShellEngine","NavigationBottom","navigation","value","onValueChange","primaryAction","navigationMaterial","bottomActionBehavior","testID","collapseProgress","useScreen","jsx","actionBehavior","material","items","map","item","name","label","icon","minimizeProgress","action","undefined","AppShell","active","navigationPlacement","sidebar","scroll","title","breadcrumb","actions","header","children","contentMaxWidth","overlay","style","windowWidth","useWindowDimensions","containerWidth","setContainerWidth","useState","colors","useTheme","key","sidebarItems","useMemo","onPress","props","isValidElement","cloneElement","Fragment","selected","docked","surface","select","next","find","candidate","onNavigate","href","window","location","assign","shellProps","bottom","length","jsxs","View","onLayout","event","nativeEvent","layout","flex","minHeight","flexDirection","backgroundColor","background","ResponsiveNavigation","flexShrink","paddingTop","paddingBottom","paddingLeft","paddingRight","gap","shownPlacement","Sidebar","showSearch","showThemeToggle","variant","height","Screen","navigationScope","documentScroll","minWidth","PageHeader","subtitle","sticky","bottomBar","ScreenScrollView","maxWidth","alignSelf","padding","EngineNavigationShell","measuredWidth","setMeasuredWidth","navFrom","Number","MAX_SAFE_INTEGER","navExpandedFrom","breakpointPx","globalThis","mappedItems","iconProps","hasNavigation","compact","engineScroll","document","resolveScrollMode","mappedSidebar","leading","AppShellMenuButton","bottomBarVisibility","floatingAction","AdaptiveAppShell","ComposedAppShell","adaptive","Platform","OS","usesLayout","panel","panelColorPreset","aside","list","info","contentWidth","navigationAlign","navigationGap","drawer","topBar","displayName"],"sourceRoot":"../../../src","sources":["app-shell/AppShell.tsx"],"mappings":";;;;;;;AAAA,IAAAA,MAAA,GAAAC,uBAAA,CAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AACA,IAAAE,YAAA,GAAAF,OAAA;AACA,IAAAG,MAAA,GAAAH,OAAA;AACA,IAAAI,OAAA,GAAAJ,OAAA;AACA,IAAAK,SAAA,GAAAL,OAAA;AACA,IAAAM,OAAA,GAAAN,OAAA;AAGA,IAAAO,qBAAA,GAAAP,OAAA;AAEA,IAAAQ,eAAA,GAAAR,OAAA;AACA,IAAAS,OAAA,GAAAT,OAAA;AACA,IAAAU,mBAAA,GAAAV,OAAA;AACA,IAAAW,UAAA,GAAAX,OAAA;AAA2C,IAAAY,WAAA,GAAAZ,OAAA;AAAA,SAAAD,wBAAAc,CAAA,EAAAC,CAAA,6BAAAC,OAAA,MAAAC,CAAA,OAAAD,OAAA,IAAAE,CAAA,OAAAF,OAAA,YAAAhB,uBAAA,YAAAA,CAAAc,CAAA,EAAAC,CAAA,SAAAA,CAAA,IAAAD,CAAA,IAAAA,CAAA,CAAAK,UAAA,SAAAL,CAAA,MAAAM,CAAA,EAAAC,CAAA,EAAAC,CAAA,KAAAC,SAAA,QAAAC,OAAA,EAAAV,CAAA,iBAAAA,CAAA,uBAAAA,CAAA,yBAAAA,CAAA,SAAAQ,CAAA,MAAAF,CAAA,GAAAL,CAAA,GAAAG,CAAA,GAAAD,CAAA,QAAAG,CAAA,CAAAK,GAAA,CAAAX,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AAK,CAACkD,SAAS,KAAK3E,SAAS,IAAIyB,KAAK,CAAC2E,cAAc,KAAKpG,SAAS;IACxE,OAAO,CAACK,MAAM,KAAK,MAAM,IAAIA,MAAM,KAAK,UAAU,KAAK,CAACqG,UAAU,gBAC9D,IAAA/J,WAAA,CAAA0C,GAAA,EAACgH,gBAAgB;MAAA,GAAK5E,KAAK;MAAEpB,MAAM,EAAEA;IAAO,CAAE,CAAC,gBAC/C,IAAA1D,WAAA,CAAA0C,GAAA,EAAC2F,qBAAqB;MAAA,GAAKvD,KAAK;MAAEpB,MAAM,EAAEA;IAAO,CAAE,CAAC;EAC1D;EACAiG,gBAAgB,CAACe,WAAW,GAAG,UAAU;EACzC,OAAOf,gBAAgB;AACzB","ignoreList":[]}
|
|
1
|
+
{"version":3,"names":["_react","_interopRequireWildcard","require","_reactNative","_breakpoints","_index","_index2","_useTheme","_index3","_ResponsiveNavigation","_AppShellEngine","_layout","_AppShellMenuButton","_constants","_jsxRuntime","e","t","WeakMap","r","n","__esModule","o","i","f","__proto__","default","has","get","set","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor","resolveNavigationPlacement","width","placement","BREAKPOINTS","md","lg","createAppShell","BottomBar","Fab","panelComponents","AppShellEngine","createAppShellEngine","NavigationBottom","navigation","value","onValueChange","primaryAction","navigationMaterial","bottomActionBehavior","testID","collapseProgress","useScreen","jsx","actionBehavior","material","items","map","item","name","label","icon","minimizeProgress","action","undefined","AppShell","active","navigationPlacement","sidebar","scroll","title","breadcrumb","actions","header","children","contentMaxWidth","overlay","style","windowWidth","useWindowDimensions","containerWidth","setContainerWidth","useState","colors","useTheme","key","sidebarItems","useMemo","onPress","props","isValidElement","cloneElement","Fragment","selected","docked","surface","select","next","find","candidate","onNavigate","href","window","location","assign","shellProps","bottom","length","jsxs","View","onLayout","event","nativeEvent","layout","flex","minHeight","flexDirection","backgroundColor","background","ResponsiveNavigation","flexShrink","paddingTop","paddingBottom","paddingLeft","paddingRight","gap","shownPlacement","Sidebar","showSearch","showThemeToggle","variant","height","Screen","navigationScope","documentScroll","minWidth","PageHeader","subtitle","sticky","bottomBar","ScreenScrollView","maxWidth","alignSelf","padding","EngineNavigationShell","measuredWidth","setMeasuredWidth","navFrom","Number","MAX_SAFE_INTEGER","navExpandedFrom","breakpointPx","globalThis","mappedItems","iconProps","hasNavigation","compact","engineScroll","document","resolveScrollMode","mappedSidebar","leading","AppShellMenuButton","accessibilityLabel","drawerOpenLabel","bottomBarVisibility","floatingAction","AdaptiveAppShell","ComposedAppShell","adaptive","Platform","OS","usesLayout","panel","panelColorPreset","aside","list","info","contentWidth","navigationAlign","navigationGap","drawer","topBar","displayName"],"sourceRoot":"../../../src","sources":["app-shell/AppShell.tsx"],"mappings":";;;;;;;AAAA,IAAAA,MAAA,GAAAC,uBAAA,CAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AACA,IAAAE,YAAA,GAAAF,OAAA;AACA,IAAAG,MAAA,GAAAH,OAAA;AACA,IAAAI,OAAA,GAAAJ,OAAA;AACA,IAAAK,SAAA,GAAAL,OAAA;AACA,IAAAM,OAAA,GAAAN,OAAA;AAGA,IAAAO,qBAAA,GAAAP,OAAA;AAEA,IAAAQ,eAAA,GAAAR,OAAA;AACA,IAAAS,OAAA,GAAAT,OAAA;AACA,IAAAU,mBAAA,GAAAV,OAAA;AACA,IAAAW,UAAA,GAAAX,OAAA;AAA2C,IAAAY,WAAA,GAAAZ,OAAA;AAAA,SAAAD,wBAAAc,CAAA,EAAAC,CAAA,6BAAAC,OAAA,MAAAC,CAAA,OAAAD,OAAA,IAAAE,CAAA,OAAAF,OAAA,YAAAhB,uBAAA,YAAAA,CAAAc,CAAA,EAAAC,CAAA,SAAAA,CAAA,IAAAD,CAAA,IAAAA,CAAA,CAAAK,UAAA,SAAAL,CAAA,MAAAM,CAAA,EAAAC,CAAA,EAAAC,CAAA,KAAAC,SAAA,QAAAC,OAAA,EAAAV,CAAA,iBAAAA,CAAA,uBAAAA,CAAA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4F,MAAM,KAAKrH,SAAS,IAC1IyB,KAAK,CAAC0D,OAAO,KAAKnF,SAAS,IAAIyB,KAAK,CAAC6D,eAAe,KAAKtF,SAAS,IAAIyB,KAAK,CAAC6F,MAAM,KAAKtH,SAAS,IAChGyB,KAAK,CAACkD,SAAS,KAAK3E,SAAS,IAAIyB,KAAK,CAAC6E,cAAc,KAAKtG,SAAS;IACxE,OAAO,CAACK,MAAM,KAAK,MAAM,IAAIA,MAAM,KAAK,UAAU,KAAK,CAACuG,UAAU,gBAC9D,IAAAjK,WAAA,CAAA0C,GAAA,EAACkH,gBAAgB;MAAA,GAAK9E,KAAK;MAAEpB,MAAM,EAAEA;IAAO,CAAE,CAAC,gBAC/C,IAAA1D,WAAA,CAAA0C,GAAA,EAAC2F,qBAAqB;MAAA,GAAKvD,KAAK;MAAEpB,MAAM,EAAEA;IAAO,CAAE,CAAC;EAC1D;EACAmG,gBAAgB,CAACe,WAAW,GAAG,UAAU;EACzC,OAAOf,gBAAgB;AACzB","ignoreList":[]}
|
|
@@ -10,6 +10,7 @@ var _react = _interopRequireWildcard(require("react"));
|
|
|
10
10
|
var _reactNative = require("react-native");
|
|
11
11
|
var _reactNativeReanimated = _interopRequireWildcard(require("react-native-reanimated"));
|
|
12
12
|
var _useControllableState = require("../hooks/use-controllable-state.js");
|
|
13
|
+
var _useIsRtl = require("../hooks/use-is-rtl.js");
|
|
13
14
|
var _index = require("../overlay/index.js");
|
|
14
15
|
var _portal = require("../portal");
|
|
15
16
|
var _index2 = require("../sidebar/index.js");
|
|
@@ -36,11 +37,11 @@ function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r
|
|
|
36
37
|
* nav the sidebar in flow from `navFrom` (`lg` for the panel, `sm` for
|
|
37
38
|
* a rail, `sm` whenever `navExpandedFrom` swaps the two); below it
|
|
38
39
|
* the same props drive the drawer. `overlay` pads the whole frame
|
|
39
|
-
* by `gutter`, `reveal` sits the rail 12 from the top-
|
|
40
|
+
* by `gutter`, `reveal` sits the rail 12 from the top-start corner
|
|
40
41
|
* page `dashboard` one fluid column capped at `contentMaxWidth`;
|
|
41
42
|
* `feed`/`focus` a `contentWidth` reading column centred in what
|
|
42
43
|
* the nav leaves; `split` a column of header over three panes
|
|
43
|
-
* aside optional right
|
|
44
|
+
* aside optional end-side column (right in LTR), `asideWidth` (320) wide from `asideFrom`
|
|
44
45
|
* (xl), pinned like the rail; below it stacked after the content
|
|
45
46
|
* slots `topBar` above the columns, `bottomBar` pinned to the bottom
|
|
46
47
|
* with the safe-area inset, `floatingAction` above that bar —
|
|
@@ -48,7 +49,7 @@ function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r
|
|
|
48
49
|
* below nav the header grows a hamburger (also with no title — see
|
|
49
50
|
* `useAppShell` / `AppShellMenuButton`). `overlay` opens the rail
|
|
50
51
|
* as a drawer (12 inset) over a 40% black backdrop; `reveal`
|
|
51
|
-
* slides the page 272
|
|
52
|
+
* slides the page 272 toward the end edge and rounds it to 32 while the rail,
|
|
52
53
|
* flat beneath it, scales up from 0.94 and fades in (325ms,
|
|
53
54
|
* cubic-bezier(0.42, 0, 0.58, 1)); pressing the page (a 10% black
|
|
54
55
|
* / 5% white veil) closes it
|
|
@@ -147,6 +148,8 @@ function createAppShellEngine(ContentPanel, BloomColorScope) {
|
|
|
147
148
|
overlay,
|
|
148
149
|
drawerOpen,
|
|
149
150
|
onDrawerOpenChange,
|
|
151
|
+
drawerOpenLabel = 'Open navigation',
|
|
152
|
+
drawerCloseLabel = 'Close navigation',
|
|
150
153
|
scroll = 'document',
|
|
151
154
|
style,
|
|
152
155
|
testID
|
|
@@ -209,6 +212,15 @@ function createAppShellEngine(ContentPanel, BloomColorScope) {
|
|
|
209
212
|
// says, rather than being rendered where nothing can reach it.
|
|
210
213
|
const asideStacked = hasAside && !asideBeside && asideCollapse === 'stack' && !canvas;
|
|
211
214
|
const reducedMotion = (0, _reactNativeReanimated.useReducedMotion)();
|
|
215
|
+
// Insets here are logical; a `translateX` sign and a `transformOrigin` are
|
|
216
|
+
// not, so the reveal reads the direction once here.
|
|
217
|
+
const rtl = (0, _useIsRtl.useIsRtl)();
|
|
218
|
+
const dir = rtl ? -1 : 1;
|
|
219
|
+
const railOrigin = rtl ? 'right center' : 'left center';
|
|
220
|
+
// react-native-web resolves logical insets against its OWN direction context
|
|
221
|
+
// (a `dir` prop), not `<html dir>` — every root and the portaled drawer hand
|
|
222
|
+
// it on.
|
|
223
|
+
const dirProps = (0, _useIsRtl.useDirectionProps)();
|
|
212
224
|
const [open, setOpen] = (0, _useControllableState.useControllableState)({
|
|
213
225
|
value: drawerOpen,
|
|
214
226
|
defaultValue: false,
|
|
@@ -323,6 +335,7 @@ function createAppShellEngine(ContentPanel, BloomColorScope) {
|
|
|
323
335
|
actions: actions,
|
|
324
336
|
menuOpen: isOpen,
|
|
325
337
|
showMenu: menuInHeader,
|
|
338
|
+
menuLabel: drawerOpenLabel,
|
|
326
339
|
onMenuPress: menuInHeader ? shell.toggleDrawer : undefined,
|
|
327
340
|
testID: testID ? `${testID}-header` : undefined
|
|
328
341
|
}) : null;
|
|
@@ -390,9 +403,9 @@ function createAppShellEngine(ContentPanel, BloomColorScope) {
|
|
|
390
403
|
}, [isOpen, drawerStyle, reducedMotion, reveal]);
|
|
391
404
|
const feedPageStyle = (0, _reactNativeReanimated.useAnimatedStyle)(() => ({
|
|
392
405
|
transform: reveal.value === 0 ? [] : [{
|
|
393
|
-
translateX: (REVEAL_OFFSET + 12) * reveal.value
|
|
406
|
+
translateX: dir * (REVEAL_OFFSET + 12) * reveal.value
|
|
394
407
|
}]
|
|
395
|
-
}), [reveal]);
|
|
408
|
+
}), [reveal, dir]);
|
|
396
409
|
const feedChromeTransition = _reactNative.Platform.OS === 'web' ? {
|
|
397
410
|
'--bloom-panel-inset-duration': reducedMotion ? '0ms' : `${REVEAL_MS}ms`
|
|
398
411
|
} : {};
|
|
@@ -413,10 +426,10 @@ function createAppShellEngine(ContentPanel, BloomColorScope) {
|
|
|
413
426
|
}), [reveal]);
|
|
414
427
|
const pageStyle = (0, _reactNativeReanimated.useAnimatedStyle)(() => ({
|
|
415
428
|
transform: reveal.value === 0 ? [] : [{
|
|
416
|
-
translateX: REVEAL_OFFSET * reveal.value
|
|
429
|
+
translateX: dir * REVEAL_OFFSET * reveal.value
|
|
417
430
|
}],
|
|
418
431
|
borderRadius: 32 * reveal.value
|
|
419
|
-
}), [reveal]);
|
|
432
|
+
}), [reveal, dir]);
|
|
420
433
|
const veilStyle = (0, _reactNativeReanimated.useAnimatedStyle)(() => ({
|
|
421
434
|
opacity: reveal.value
|
|
422
435
|
}), [reveal]);
|
|
@@ -424,6 +437,7 @@ function createAppShellEngine(ContentPanel, BloomColorScope) {
|
|
|
424
437
|
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_context.AppShellProvider, {
|
|
425
438
|
value: shell,
|
|
426
439
|
children: /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
|
|
440
|
+
...dirProps,
|
|
427
441
|
testID: testID,
|
|
428
442
|
onLayout: onLayout,
|
|
429
443
|
style: [frame, doc ? {
|
|
@@ -438,7 +452,7 @@ function createAppShellEngine(ContentPanel, BloomColorScope) {
|
|
|
438
452
|
} : {
|
|
439
453
|
paddingTop: 12,
|
|
440
454
|
paddingBottom: 12,
|
|
441
|
-
|
|
455
|
+
paddingInlineStart: 12,
|
|
442
456
|
flexShrink: 0
|
|
443
457
|
}, doc ? (0, _layout.stickyRail)(0) : null],
|
|
444
458
|
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_index2.Sidebar, {
|
|
@@ -454,17 +468,17 @@ function createAppShellEngine(ContentPanel, BloomColorScope) {
|
|
|
454
468
|
position: doc ? _webViewStyle.WEB_POSITION_FIXED : 'absolute',
|
|
455
469
|
top: 0,
|
|
456
470
|
bottom: 0,
|
|
457
|
-
|
|
471
|
+
insetInlineStart: 0,
|
|
458
472
|
width: 272,
|
|
459
473
|
paddingTop: 12,
|
|
460
474
|
paddingBottom: 12,
|
|
461
|
-
|
|
475
|
+
paddingInlineStart: 6
|
|
462
476
|
},
|
|
463
477
|
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNativeReanimated.default.View, {
|
|
464
478
|
style: [{
|
|
465
479
|
height: '100%',
|
|
466
480
|
width: 260,
|
|
467
|
-
transformOrigin:
|
|
481
|
+
transformOrigin: railOrigin
|
|
468
482
|
}, railStyle],
|
|
469
483
|
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_index2.Sidebar, {
|
|
470
484
|
...drawerSidebar,
|
|
@@ -509,7 +523,7 @@ function createAppShellEngine(ContentPanel, BloomColorScope) {
|
|
|
509
523
|
}), asideColumn({
|
|
510
524
|
paddingTop: small ? 24 : 12,
|
|
511
525
|
paddingBottom: 12,
|
|
512
|
-
|
|
526
|
+
paddingInlineEnd: 12
|
|
513
527
|
}), !wide ? /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNativeReanimated.default.View, {
|
|
514
528
|
pointerEvents: isOpen ? 'auto' : 'none',
|
|
515
529
|
style: [{
|
|
@@ -521,7 +535,7 @@ function createAppShellEngine(ContentPanel, BloomColorScope) {
|
|
|
521
535
|
}, veilStyle],
|
|
522
536
|
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Pressable, {
|
|
523
537
|
role: "button",
|
|
524
|
-
accessibilityLabel:
|
|
538
|
+
accessibilityLabel: drawerCloseLabel,
|
|
525
539
|
focusable: isOpen,
|
|
526
540
|
onPress: () => setOpen(false),
|
|
527
541
|
style: {
|
|
@@ -813,14 +827,15 @@ function createAppShellEngine(ContentPanel, BloomColorScope) {
|
|
|
813
827
|
children: children
|
|
814
828
|
})]
|
|
815
829
|
}), asideColumn(canvas ? {
|
|
816
|
-
|
|
817
|
-
|
|
830
|
+
paddingTop: gutter,
|
|
831
|
+
paddingBottom: gutter,
|
|
832
|
+
paddingInlineEnd: gutter
|
|
818
833
|
} : {})]
|
|
819
834
|
});
|
|
820
835
|
const body = variant === 'split' ? splitBody : canvas ? canvasBody : centred ? centredBody : dashboardBody;
|
|
821
836
|
|
|
822
837
|
// A DOCKED nav is flush to the window: it takes the shell's whole height and
|
|
823
|
-
// its own hairline is the separator, so the shell gives up its
|
|
838
|
+
// its own hairline is the separator, so the shell gives up its start and
|
|
824
839
|
// vertical padding around that column rather than framing it like a card.
|
|
825
840
|
const dockedNav = navInFlow && flowSidebar?.surface === 'docked';
|
|
826
841
|
const navRegion = navInFlow && flowSidebar ? doc ? /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
|
|
@@ -834,8 +849,9 @@ function createAppShellEngine(ContentPanel, BloomColorScope) {
|
|
|
834
849
|
// The canvas row has no padding of its own, so the nav states its.
|
|
835
850
|
(0, _jsxRuntime.jsx)(_reactNative.View, {
|
|
836
851
|
style: {
|
|
837
|
-
|
|
838
|
-
|
|
852
|
+
paddingTop: gutter,
|
|
853
|
+
paddingBottom: gutter,
|
|
854
|
+
paddingInlineStart: gutter,
|
|
839
855
|
flexShrink: 0
|
|
840
856
|
},
|
|
841
857
|
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_index2.Sidebar, {
|
|
@@ -850,14 +866,15 @@ function createAppShellEngine(ContentPanel, BloomColorScope) {
|
|
|
850
866
|
onPress: () => setOpen(false),
|
|
851
867
|
blurIntensity: 0,
|
|
852
868
|
dimOpacity: 0.4,
|
|
853
|
-
accessibilityLabel:
|
|
869
|
+
accessibilityLabel: drawerCloseLabel
|
|
854
870
|
}), /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
|
|
871
|
+
...dirProps,
|
|
855
872
|
pointerEvents: "box-none",
|
|
856
873
|
style: {
|
|
857
874
|
position: 'absolute',
|
|
858
875
|
top: 0,
|
|
859
876
|
bottom: 0,
|
|
860
|
-
|
|
877
|
+
insetInlineStart: 0,
|
|
861
878
|
flexDirection: 'row',
|
|
862
879
|
padding: 12
|
|
863
880
|
},
|
|
@@ -883,18 +900,25 @@ function createAppShellEngine(ContentPanel, BloomColorScope) {
|
|
|
883
900
|
gap: dockedNav || canvas ? 0 : Math.max(0, navigationGap ?? columnGap),
|
|
884
901
|
// A canvas runs to the window's edge, so the row keeps no padding at all
|
|
885
902
|
// and each region carries its own (the nav below, the aside in `canvasBody`).
|
|
886
|
-
|
|
903
|
+
// A docked nav keeps only the END padding. Spelled in longhands, never the
|
|
904
|
+
// `padding` shorthand plus a logical override: react-native-web expands the
|
|
905
|
+
// shorthand to physical sides, and which of two declarations for one edge
|
|
906
|
+
// wins is then a matter of declaration order rather than intent.
|
|
887
907
|
...(dockedNav ? {
|
|
888
|
-
paddingLeft: 0,
|
|
889
908
|
paddingTop: 0,
|
|
890
|
-
paddingBottom: 0
|
|
891
|
-
|
|
909
|
+
paddingBottom: 0,
|
|
910
|
+
paddingInlineStart: 0,
|
|
911
|
+
paddingInlineEnd: canvas || plainDocumentFrame ? 0 : gutter
|
|
912
|
+
} : {
|
|
913
|
+
padding: canvas || plainDocumentFrame ? 0 : gutter
|
|
914
|
+
}),
|
|
892
915
|
backgroundColor: background
|
|
893
916
|
};
|
|
894
917
|
if (variant === 'feed' && drawerStyle === 'reveal' && drawerAvailable) {
|
|
895
918
|
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_context.AppShellProvider, {
|
|
896
919
|
value: shell,
|
|
897
920
|
children: /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
|
|
921
|
+
...dirProps,
|
|
898
922
|
testID: testID,
|
|
899
923
|
onLayout: onLayout,
|
|
900
924
|
style: [frame, {
|
|
@@ -908,17 +932,17 @@ function createAppShellEngine(ContentPanel, BloomColorScope) {
|
|
|
908
932
|
position: doc ? _webViewStyle.WEB_POSITION_FIXED : 'absolute',
|
|
909
933
|
top: 0,
|
|
910
934
|
bottom: 0,
|
|
911
|
-
|
|
935
|
+
insetInlineStart: 0,
|
|
912
936
|
width: 272,
|
|
913
937
|
paddingTop: 12,
|
|
914
938
|
paddingBottom: 12,
|
|
915
|
-
|
|
939
|
+
paddingInlineStart: 6
|
|
916
940
|
},
|
|
917
941
|
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNativeReanimated.default.View, {
|
|
918
942
|
style: [{
|
|
919
943
|
height: '100%',
|
|
920
944
|
width: 260,
|
|
921
|
-
transformOrigin:
|
|
945
|
+
transformOrigin: railOrigin
|
|
922
946
|
}, railStyle],
|
|
923
947
|
children: drawerSidebar && /*#__PURE__*/(0, _jsxRuntime.jsx)(_index2.Sidebar, {
|
|
924
948
|
...drawerSidebar,
|
|
@@ -955,7 +979,7 @@ function createAppShellEngine(ContentPanel, BloomColorScope) {
|
|
|
955
979
|
}, veilStyle],
|
|
956
980
|
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Pressable, {
|
|
957
981
|
role: "button",
|
|
958
|
-
accessibilityLabel:
|
|
982
|
+
accessibilityLabel: drawerCloseLabel,
|
|
959
983
|
focusable: isOpen,
|
|
960
984
|
onPress: () => setOpen(false),
|
|
961
985
|
testID: testID ? `${testID}-veil` : undefined,
|
|
@@ -993,6 +1017,7 @@ function createAppShellEngine(ContentPanel, BloomColorScope) {
|
|
|
993
1017
|
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_context.AppShellProvider, {
|
|
994
1018
|
value: shell,
|
|
995
1019
|
children: /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
|
|
1020
|
+
...dirProps,
|
|
996
1021
|
testID: testID,
|
|
997
1022
|
onLayout: onLayout,
|
|
998
1023
|
style: [frame, {
|
|
@@ -1013,6 +1038,7 @@ function createAppShellEngine(ContentPanel, BloomColorScope) {
|
|
|
1013
1038
|
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_context.AppShellProvider, {
|
|
1014
1039
|
value: shell,
|
|
1015
1040
|
children: /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
|
|
1041
|
+
...dirProps,
|
|
1016
1042
|
testID: testID,
|
|
1017
1043
|
onLayout: onLayout,
|
|
1018
1044
|
style: [frame, rowStyle, style],
|