@skirbi/pinta 0.0.40 → 0.0.41

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/Changes CHANGED
@@ -1,5 +1,15 @@
1
1
  Revision history for @skirbi/pinta
2
2
 
3
+ 0.0.41 2026-09-16 05:32:35Z
4
+
5
+ * semtic-nav-page: fixed the flex recipe to target semtic-nav-page-item
6
+ directly, following the component's own removal of a wrapper div that
7
+ used to sit between them. Default is now a stacked column; the new
8
+ side-by-side attribute switches to the previous two-column,
9
+ edge-to-edge layout. Title truncation now has a real bounded column to
10
+ truncate against. Stacked gap widened to 1rem, side-by-side gap to
11
+ 2rem, so hover backgrounds no longer touch in either layout.
12
+
3
13
  0.0.40 2026-09-16 04:30:30Z
4
14
 
5
15
  * Add default styling for semtic-nav-page/semtic-nav-page-item: previous
package/lib/index.mjs CHANGED
@@ -2,4 +2,4 @@
2
2
  //
3
3
  // SPDX-License-Identifier: MIT
4
4
 
5
- const VERSION = "0.0.40";
5
+ const VERSION = "0.0.41";
@@ -4962,33 +4962,57 @@
4962
4962
  * @description
4963
4963
  *
4964
4964
  * Default recipe for `<semtic-nav-page>` and its `<semtic-nav-page-item>`
4965
- * sides. The previous item hugs the nav's start edge, the next item its end
4966
- * edge -- edge to edge within whatever column the nav itself sits in (the
4967
- * article's content column, typically), not the page's outer aside rails.
4965
+ * sides, within whatever column the nav itself sits in (the article's
4966
+ * content column, typically), not the page's outer aside rails.
4967
+ *
4968
+ * Stacked by default: previous above next, each a full-width row. The
4969
+ * `side-by-side` attribute lays them out as two columns instead, previous
4970
+ * on the nav's start edge and next on its end edge.
4968
4971
  */
4969
4972
  [skirbi-theme] {
4970
4973
  semtic-nav-page > nav {
4971
4974
  display: flex;
4972
- justify-content: space-between;
4975
+ flex-direction: column;
4976
+ /* >= 2x the item link's own negative margin (0.5rem), so two
4977
+ * stacked items' hover backgrounds never touch or overlap. */
4973
4978
  gap: 1rem;
4974
4979
  margin-block-start: 2rem;
4975
4980
  padding-block-start: 1.5rem;
4976
4981
  border-block-start: 1px solid var(--skirbi-surface-border-final);
4982
+
4983
+ /* Grid, not flex: a lone item (the first/last page in a section)
4984
+ * must still only occupy its own half -- flex would let a single
4985
+ * flex: 1 1 0 child stretch across the whole row once the other
4986
+ * side is missing. Fixed 1fr/1fr columns hold the halves whether
4987
+ * one or both are present. */
4988
+ &[side-by-side] {
4989
+ display: grid;
4990
+ grid-template-columns: 1fr 1fr;
4991
+ /* Item links expand 0.5rem past their own bounds on hover (the
4992
+ * padding/negative-margin trick above); this must clear both
4993
+ * sides' worth of that or the two hover backgrounds touch. */
4994
+ gap: 2rem;
4995
+ }
4977
4996
  }
4978
4997
 
4979
4998
  semtic-nav-page-item {
4980
4999
  display: block;
4981
5000
  min-width: 0;
4982
- flex: 1 1 0;
5001
+ }
4983
5002
 
4984
- &[next] {
4985
- text-align: end;
4986
- }
5003
+ nav[side-by-side] > semtic-nav-page-item[previous] {
5004
+ grid-column: 1;
5005
+ }
5006
+
5007
+ nav[side-by-side] > semtic-nav-page-item[next] {
5008
+ grid-column: 2;
5009
+ text-align: end;
4987
5010
  }
4988
5011
 
4989
5012
  semtic-nav-page-item > a {
4990
5013
  display: flex;
4991
5014
  align-items: center;
5015
+ min-width: 0;
4992
5016
  gap: 0.75rem;
4993
5017
  padding: 0.5rem;
4994
5018
  margin: -0.5rem;
@@ -5003,10 +5027,21 @@
5003
5027
  }
5004
5028
  }
5005
5029
 
5006
- semtic-nav-page-item[next] > a {
5030
+ nav[side-by-side] > semtic-nav-page-item[next] > a {
5007
5031
  flex-direction: row-reverse;
5008
5032
  }
5009
5033
 
5034
+ [semtic-nav-page-text] {
5035
+ display: flex;
5036
+ flex-direction: column;
5037
+ min-width: 0;
5038
+ flex: 1 1 auto;
5039
+ }
5040
+
5041
+ nav[side-by-side] > semtic-nav-page-item[next] [semtic-nav-page-text] {
5042
+ align-items: flex-end;
5043
+ }
5044
+
5010
5045
  [semtic-nav-page-eyebrow] {
5011
5046
  display: block;
5012
5047
  font-size: 0.75rem;
@@ -5017,6 +5052,8 @@
5017
5052
 
5018
5053
  [semtic-nav-page-title] {
5019
5054
  display: block;
5055
+ min-width: 0;
5056
+ max-width: 100%;
5020
5057
  font-weight: 600;
5021
5058
  overflow: hidden;
5022
5059
  text-overflow: ellipsis;
package/package.json CHANGED
@@ -32,5 +32,5 @@
32
32
  },
33
33
  "sideEffects": false,
34
34
  "type": "module",
35
- "version": "0.0.40"
35
+ "version": "0.0.41"
36
36
  }