@gouvfr/dsfr-roller 1.0.33 → 1.0.35

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@gouvfr/dsfr-roller",
3
- "version": "1.0.33",
3
+ "version": "1.0.35",
4
4
  "description": "Le module `dsfr-roller` permet de publier le site de documentation du Système de Design de l’État - DSFR",
5
5
  "keywords": [
6
6
  "Système de Design de l'État",
@@ -56,7 +56,7 @@
56
56
  ],
57
57
  "main": "./index.js",
58
58
  "dependencies": {
59
- "@gouvfr/dsfr-forge": "=1.0.33",
59
+ "@gouvfr/dsfr-forge": "=1.0.35",
60
60
  "@gouvfr/dsfr-publisher": "npm:@gouvfr/dsfr@1.13.2",
61
61
  "deepmerge": "^4.3.1",
62
62
  "ejs": "^3.1.10",
@@ -18,6 +18,7 @@ class DisplayModal extends Component {
18
18
  id: 'display-modal',
19
19
  title: this.data.resource.display.title,
20
20
  size: 'sm',
21
+ titleMarkup: 'p',
21
22
  closeButton: {
22
23
  label: this.data.fragments.button.close,
23
24
  },
@@ -51,8 +51,9 @@ class Sidemenu extends Component {
51
51
  }
52
52
 
53
53
  _formatLink (link) {
54
+ const text = link.titleId ? `${link.text} (<span lang="en">${link.titleId}</span>)` : link.text;
54
55
  const badge = link.badge ? this._formatBadge(link.badge) : '';
55
- const label = link.badge ? link.text + badge : link.text;
56
+ const label = link.badge ? text + badge : text;
56
57
  return {
57
58
  ...formatLink(link),
58
59
  active: link.isCurrent,
@@ -193,8 +193,7 @@ class HpSliceVideoContainerDirective extends Node {
193
193
  classes: ['fr-modal__content'],
194
194
  children: [
195
195
  {
196
- type: 'htmlContainer',
197
- tagName: 'h3',
196
+ type: 'paragraph',
198
197
  classes: ['fr-modal__title'],
199
198
  attributes: {
200
199
  id: modalId + '-title'
@@ -436,9 +436,9 @@ export var tarteaucitron = {
436
436
  </button>
437
437
  </div>
438
438
  <div class="fr-modal__content">
439
- <h2 class="fr-modal__title fr-h3" id="fr-consent-modal-title">
439
+ <p class="fr-modal__title fr-h3" id="fr-consent-modal-title">
440
440
  ${tarteaucitron.lang.title}
441
- </h2>
441
+ </p>
442
442
  <div class="fr-consent-manager">
443
443
  <div class="fr-consent-service fr-consent-manager__header">
444
444
  <fieldset class="fr-fieldset fr-fieldset--inline">
@@ -666,14 +666,14 @@ export var tarteaucitron = {
666
666
  !tarteaucitron.parameters.AcceptAllCta
667
667
  ) {
668
668
  html += `<div tabindex="-1" id="tarteaucitronAlertBig" class="fr-consent-banner" ${modalAttrs}>`;
669
- html += `<h2 class="fr-h6">${tarteaucitron.lang.alertBigPrivacy.title}</h2>`;
669
+ html += `<p class="fr-h6">${tarteaucitron.lang.alertBigPrivacy.title}</p>`;
670
670
  html += `<div id="tarteaucitronDisclaimerAlert" class="fr-consent-banner__content"><p class="fr-text--sm">${tarteaucitron.lang.alertBigPrivacy.content}</p></div>`;
671
671
  html += `<ul class="fr-consent-banner__buttons fr-btns-group fr-btns-group--right fr-btns-group--inline-reverse fr-btns-group--inline-sm">`;
672
672
  html += `<li><button class="fr-btn fr-btn--secondary" data-fr-opened="false" aria-controls="consent-modal" aria-label="${tarteaucitron.lang.personalize} ${tarteaucitron.lang.modalWindow}" title="${tarteaucitron.lang.personalize} ${tarteaucitron.lang.modalWindow}" type="button" id="tarteaucitronPersonalize">${tarteaucitron.lang.personalize}</button></li>`;
673
673
  html += '</ul></div>';
674
674
  } else {
675
675
  html += `<div tabindex="-1" id="tarteaucitronAlertBig" class="fr-consent-banner" ${modalAttrs}>`;
676
- html += `<h2 class="fr-h6">${tarteaucitron.lang.alertBigPrivacy.title}</h2>`;
676
+ html += `<p class="fr-h6">${tarteaucitron.lang.alertBigPrivacy.title}</p>`;
677
677
  html += `<div id="tarteaucitronDisclaimerAlert" class="fr-consent-banner__content"><p class="fr-text--sm">${
678
678
  tarteaucitron.parameters.highPrivacy
679
679
  ? tarteaucitron.lang.alertBigPrivacy.content
@@ -925,7 +925,7 @@ export var tarteaucitron = {
925
925
  // The setimeout at 1500 ms will prevent the location.reload event to be properly binded...
926
926
  if (tarteaucitronNoAdBlocker === false) {
927
927
  html = `<div id="tarteaucitronAlertBig" class="fr-consent-banner tarteaucitronAlertBig tarteaucitron-display-block" role="alert" aria-live="polite">`;
928
- html += `<h2 class="fr-h6">${tarteaucitron.lang.adblock}</h2>`;
928
+ html += `<p class="fr-h6">${tarteaucitron.lang.adblock}</p>`;
929
929
  html += `<div id="tarteaucitronDisclaimerAlert" class="fr-consent-banner__content"><p class="fr-text--sm">${tarteaucitron.lang.adblock_call}</p></div>`;
930
930
  html += `<ul class="fr-consent-banner__buttons fr-btns-group fr-btns-group--right fr-btns-group--inline-reverse fr-btns-group--inline-sm">`;
931
931
  html += `<li><button class="fr-btn tarteaucitronCTAButton" aria-label="${tarteaucitron.lang.reload}" title="${tarteaucitron.lang.reload}" type="button" id="tarteaucitronCTAButton">${tarteaucitron.lang.reload}</button></li>`;
@@ -43,6 +43,13 @@
43
43
  display: none;
44
44
  }
45
45
 
46
+ &:has(+ .dsfr-doc-hp-showcase-card__link--extended:hover) {
47
+ img,
48
+ svg {
49
+ transform: scale(1.05);
50
+ }
51
+ }
52
+
46
53
  img,
47
54
  svg {
48
55
  transition: transform 0.3s ease-out;
@@ -50,13 +57,6 @@
50
57
  width: 100%;
51
58
  height: auto;
52
59
  }
53
-
54
- &:hover {
55
- img,
56
- svg {
57
- transform: scale(1.05);
58
- }
59
- }
60
60
  }
61
61
 
62
62
  &__links-group {
@@ -80,7 +80,7 @@
80
80
  top: 0;
81
81
  left: 0;
82
82
  width: 100%;
83
- height: 100%;
83
+ height: calc(100% - 2.25rem);
84
84
  }
85
85
  }
86
86
  }
@@ -120,6 +120,10 @@
120
120
  }
121
121
  }
122
122
  }
123
+
124
+ &__link--extended::before {
125
+ height: calc(100% - 2.5rem);
126
+ }
123
127
  }
124
128
 
125
129
  &__title {
@@ -0,0 +1,5 @@
1
+ .dsfr-doc-storybook-leaf {
2
+ .dsfr-iframe-storybook-root {
3
+ border: 1px solid var(--border-default-grey);
4
+ }
5
+ }
@@ -7,3 +7,4 @@
7
7
  @use 'dsfr-doc-searchbar';
8
8
  @use 'dsfr-doc-pagination';
9
9
  @use 'dsfr-doc-edit';
10
+ @use 'dsfr-doc-storybook-leaf';
@@ -17,7 +17,7 @@ class EditorialTemplate extends Template {
17
17
  }
18
18
 
19
19
  structure (data) {
20
- this._hasEditUrl = data?.editUrl !== undefined;
20
+ this._hasEditUrl = data?.editUrl != null;
21
21
  if (this._hasEditUrl) {
22
22
  const edit = new Edit({...data.resource.edit, editUrl: data.editUrl, blankLabel: data.fragments.blank});
23
23
  data.nodes.push(edit.node);