@datagouv/components-next 1.0.2-dev.183 → 1.0.2-dev.185

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.
@@ -1,4 +1,4 @@
1
- import { g as Ke } from "./main-OEOVgq_i.js";
1
+ import { g as Ke } from "./main-BgsOe_n1.js";
2
2
  import We from "vue";
3
3
  function Fe($, K) {
4
4
  for (var V = 0; V < K.length; V++) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@datagouv/components-next",
3
- "version": "1.0.2-dev.183",
3
+ "version": "1.0.2-dev.185",
4
4
  "private": false,
5
5
  "type": "module",
6
6
  "engines": {
@@ -228,6 +228,7 @@
228
228
  size="sm"
229
229
  :icon="RiRssLine"
230
230
  icon-only
231
+ external
231
232
  target="_blank"
232
233
  />
233
234
  </div>
@@ -11,7 +11,10 @@
11
11
  :class="{ 'rotate-180': open }"
12
12
  />
13
13
  </button>
14
- <div v-if="open || !isMobile">
14
+ <!-- Collapsing with CSS rather than `v-if` on a JS media query: the server has no
15
+ viewport, so it always renders the desktop state and a narrow client would drop
16
+ the whole panel during hydration. -->
17
+ <div :class="{ 'hidden md:block': !open }">
15
18
  <p
16
19
  :id="titleId"
17
20
  class="text-sm font-bold leading-tight mb-6 hidden md:block"
@@ -26,13 +29,11 @@
26
29
  <script setup lang="ts">
27
30
  import { ref, useId } from 'vue'
28
31
  import { RiArrowDownSLine } from '@remixicon/vue'
29
- import { useMediaQuery } from '@vueuse/core'
30
32
 
31
33
  defineProps<{
32
34
  buttonText: string
33
35
  }>()
34
36
 
35
37
  const titleId = useId()
36
- const isMobile = useMediaQuery('(max-width: 767px)')
37
38
  const open = ref(false)
38
39
  </script>