keystone_ui 0.58.0 → 0.59.0
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.
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: fa286726a479f478774e33da15f8ec93767df8e20227a6280e3835e575740333
|
|
4
|
+
data.tar.gz: f1e259b398cca001b2174f90ebfe5ed0a9810ea7a9fc5f965d8c7c8abf55eb58
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: b6ae5646277a7ddac4b926f709efaac74f4f3097c83cbb07ac8d24ac7a468e31086ba91327eef2da4b9fcaedfb384b8c64f4c22f663343294c3051481ec013e2
|
|
7
|
+
data.tar.gz: f27bd1e717b7e0604480eec0d8500f18dfcbcac1dbe4ca8489fe468c0b1e33c1cde6aa807b8fbd6a71513afe2c3cc4ec4d50e73da9135d02eea0623fa28b3199
|
|
@@ -15,10 +15,10 @@ module Keystone
|
|
|
15
15
|
</svg>
|
|
16
16
|
SVG
|
|
17
17
|
|
|
18
|
-
WRAPPER_CLASSES = "lg:hidden print:hidden"
|
|
18
|
+
WRAPPER_CLASSES = "flex items-center lg:hidden print:hidden"
|
|
19
19
|
BACK_LINK_CLASSES = "ks-mobile-header-back"
|
|
20
|
-
TITLE_CLASSES = "ks-mobile-header-title
|
|
21
|
-
SUBTITLE_CLASSES = "ks-mobile-header-subtitle block text-xs truncate
|
|
20
|
+
TITLE_CLASSES = "ks-mobile-header-title flex-[1_1_6rem] min-w-0 self-center lg:hidden truncate"
|
|
21
|
+
SUBTITLE_CLASSES = "ks-mobile-header-subtitle block text-xs truncate"
|
|
22
22
|
DROPDOWN_CLASSES = "ks-action-menu hidden absolute right-0 z-50 w-48 origin-top-right"
|
|
23
23
|
|
|
24
24
|
# Renders the left-side and title of the mobile header.
|
|
@@ -3,14 +3,14 @@
|
|
|
3
3
|
module Keystone
|
|
4
4
|
module Ui
|
|
5
5
|
class NavbarComponent < ViewComponent::Base
|
|
6
|
-
NAV_BASE = "top-nav print:hidden"
|
|
6
|
+
NAV_BASE = "top-nav print:hidden max-lg:has-[.ks-mobile-header-title]:flex-wrap"
|
|
7
7
|
NAV_STICKY = "sticky top-0 z-40"
|
|
8
|
-
MOBILE_LEFT_CLASSES = "lg:hidden flex items-center"
|
|
8
|
+
MOBILE_LEFT_CLASSES = "lg:hidden flex items-center max-lg:has-[.ks-mobile-header-title]:contents"
|
|
9
9
|
LOGO_CLASSES = "logo"
|
|
10
10
|
LOGO_MOBILE_HIDDEN_CLASSES = "hidden lg:flex"
|
|
11
11
|
MOBILE_CENTER_CLASSES = "ks-navbar-title absolute left-1/2 -translate-x-1/2 lg:hidden truncate max-w-[60%]"
|
|
12
12
|
DESKTOP_LINKS_CLASSES = "nav-container hidden lg:flex"
|
|
13
|
-
MOBILE_RIGHT_CLASSES = "nav-user-controls ml-auto"
|
|
13
|
+
MOBILE_RIGHT_CLASSES = "nav-user-controls ml-auto max-lg:in-[.top-nav:has(.ks-mobile-header-title)]:flex-wrap max-lg:in-[.top-nav:has(.ks-mobile-header-title)]:justify-end"
|
|
14
14
|
|
|
15
15
|
renders_one :logo
|
|
16
16
|
renders_one :desktop_links
|
data/lib/keystone_ui/version.rb
CHANGED
|
@@ -40,7 +40,7 @@ not available in the app yet, that is `keystone_ui-install`'s job.
|
|
|
40
40
|
- `ui_nav_dropdown` — a navbar dropdown menu.
|
|
41
41
|
- `ui_bottom_nav` — the mobile bottom tab bar.
|
|
42
42
|
- `ui_bottom_nav_item` — one tab in the bottom tab bar.
|
|
43
|
-
- `ui_mobile_header` — a mobile back arrow and
|
|
43
|
+
- `ui_mobile_header` — a mobile back arrow and a title beside it.
|
|
44
44
|
- `ui_mobile_actions` — an ellipsis menu of actions shown only below `lg:`.
|
|
45
45
|
- `ui_mobile_action` — a plus icon link to the action a screen's page header publishes, for the phone top bar.
|
|
46
46
|
- `ui_action_menu` — an ellipsis menu of actions shown at every screen size.
|
|
@@ -257,7 +257,13 @@ two exceptions: `ui_page`'s `padding:` treats any value other than `:none` as
|
|
|
257
257
|
Hotwire Native web view.
|
|
258
258
|
- `ui_mobile_header(title:, back_url:, subtitle: nil)` is hidden from `lg:`
|
|
259
259
|
up and goes in the navbar's `mobile_left` slot. `back_url:` must be
|
|
260
|
-
passed, and `nil` renders the title with no back arrow.
|
|
260
|
+
passed, and `nil` renders the title with no back arrow. The title and
|
|
261
|
+
subtitle sit between the arrow and the right-side controls, start at the
|
|
262
|
+
left, and end in an ellipsis when too long. In `ui_navbar`, controls that
|
|
263
|
+
leave less than 6rem for the title move to a second row under it. In a
|
|
264
|
+
hand-written top bar, make the header a direct child of the bar's flex
|
|
265
|
+
row, and add `max-lg:has-[.ks-mobile-header-title]:flex-wrap` to the bar if
|
|
266
|
+
its controls can fill its width.
|
|
261
267
|
- `ui_mobile_action` takes no keywords and no block, and goes in the top
|
|
262
268
|
bar's right side, such as the navbar's `mobile_right` slot. It draws a plus
|
|
263
269
|
icon linking to the `action_url:` a screen gives `ui_page_header`, named
|