origam 2.37.3 → 2.37.5

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
@@ -18,6 +18,25 @@ This project follows [Semantic Versioning](https://semver.org).
18
18
 
19
19
  ## [Unreleased]
20
20
 
21
+ ## [2.37.5] - 2026-10-21
22
+
23
+ ### Fixed — `OrigamTabPanels` ne relaie plus `transition` à `OrigamTabPanel` (#1207)
24
+
25
+ `OrigamTabPanels` enveloppait son slot dans un `<origam-defaults-provider>` qui poussait `transition` à `origam-tab-panel`, qui ne déclare pas cette prop et lit déjà la transition depuis le contexte des panneaux. Le résolveur de props de thème émettait donc un avertissement de dev à chaque `OrigamCodeGroup`.
26
+
27
+ - Le provider et son `slotDefaults` sont retirés ; la transition continue de passer par le contexte.
28
+ - Vérifié : TU `tab-panels-transition-no-warn.spec.ts` rouge sur le parent, vert après (PR #1232).
29
+
30
+ ## [2.37.4] - 2026-10-20
31
+
32
+ ### Fixed — `OrigamCode` : une ligne vide tombait à 0 px et un numéro fantôme suivait le saut de ligne final (#1216)
33
+
34
+ Avec `line-numbers`, la rangée d'une ligne vide avait `min-height: var(--origam-code---line-height)`, or ce token vaut `1.6` sans unité : la déclaration était invalide et la rangée vide mesurait 0 px, son numéro se superposant à celui de la ligne suivante.
35
+
36
+ - La rangée prend désormais `min-height: 1lh`, la hauteur de ligne calculée.
37
+ - Le dernier `<span class="line"></span>` vide que shiki émet après le saut de ligne final n'est plus compté : plus de rangée ni de numéro en trop.
38
+ - Vérifié : spec e2e rouge sur le parent, verte après ; TU Code + CodeGroup 49/49 (PR #1219).
39
+
21
40
  ## [2.37.3] - 2026-10-19
22
41
 
23
42
  ### Fixed — `v-intersect` lié avec le tuple `withDirectives` : handler jamais appelé (#1205)
@@ -286,7 +286,7 @@ function paintIntoDom(rawHtml) {
286
286
  if (!target) return;
287
287
  const innerMatch = rawHtml.match(/<code[^>]*>([\s\S]*?)<\/code>/);
288
288
  const inner = innerMatch ? innerMatch[1] : rawHtml;
289
- const lines = inner.split(/\n/).filter((l, idx, arr) => !(idx === arr.length - 1 && l.trim() === ""));
289
+ const lines = inner.split(/\n/).filter((l, idx, arr) => !(idx === arr.length - 1 && l.replace(/<span class="line"><\/span>/, "").trim() === ""));
290
290
  const highlightSet = highlightedLines.value;
291
291
  const rows = lines.map((line, i) => {
292
292
  const lineNo = i + 1;
@@ -531,7 +531,11 @@ defineExpose({ rebuild, copied, codeRef });
531
531
  display: block;
532
532
  padding-inline: var(--origam-code__row---padding-inline);
533
533
  white-space: pre;
534
- min-height: var(--origam-code---line-height);
534
+ /**
535
+ * 1lh = the row's own computed line-height. The token is unitless (1.6),
536
+ * so it was an invalid min-height and an empty row collapsed to 0 px (#1216).
537
+ */
538
+ min-height: 1lh;
535
539
  }
536
540
 
537
541
  .origam-code--wrap .origam-code__row {
@@ -7,21 +7,17 @@
7
7
  :class="panelsClasses"
8
8
  :style="panelsStyles"
9
9
  >
10
- <origam-defaults-provider :defaults="slotDefaults">
11
- <slot
12
- name="default"
13
- v-bind="slotProps"
14
- />
15
- </origam-defaults-provider>
10
+ <slot
11
+ name="default"
12
+ v-bind="slotProps"
13
+ />
16
14
  </component>
17
15
  </template>
18
16
 
19
17
  <script lang="ts" setup>
20
18
  import { computed, provide, ref, shallowRef, StyleValue, watch } from "vue";
21
- import OrigamDefaultsProvider from "../DefaultsProvider/OrigamDefaultsProvider.vue";
22
19
  import { useGroup } from "../../composables/Commons/group.composable";
23
20
  import { useGroupSiblingLink } from "../../composables/Commons/groupSiblingLink.composable";
24
- import { usePassedProps } from "../../composables/Commons/passedProps.composable";
25
21
  import { useProps } from "../../composables/Commons/props.composable";
26
22
  import { useStyle } from "../../composables/Commons/style.composable";
27
23
  import {
@@ -30,7 +26,6 @@ import {
30
26
  ORIGAM_TAB_PANELS_KEY,
31
27
  ORIGAM_TAB_PANELS_CTX_KEY
32
28
  } from "../../consts/Tabs/tabs.const";
33
- import { omitUndefined } from "../../utils/Commons/commons.util";
34
29
  import vTouch from "../../directives/Touch/touch.directive";
35
30
  import { DIRECTION } from "../../enums/Commons/direction.enum";
36
31
  const props = defineProps({
@@ -86,12 +81,6 @@ const slotProps = computed(() => ({
86
81
  selected,
87
82
  items: items.value
88
83
  }));
89
- const wasPropPassed = usePassedProps(props);
90
- const slotDefaults = computed(() => ({
91
- "origam-tab-panel": omitUndefined({
92
- transition: wasPropPassed("transition") ? props.transition : void 0
93
- })
94
- }));
95
84
  const panelsStyles = computed(() => {
96
85
  return [
97
86
  props.style
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "origam",
3
- "version": "2.37.3",
3
+ "version": "2.37.5",
4
4
  "type": "module",
5
5
  "description": "origam — a Vue 3 design system with multi-theme design tokens, CSS-first components and TypeScript types.",
6
6
  "keywords": [