@iqual/nuxt-icms 1.3.0 → 1.4.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.
Files changed (122) hide show
  1. package/assets/symbols/chevron-right.svg +1 -1
  2. package/components/Blokkli/HeroImage/index.vue +1 -1
  3. package/components/Blokkli/Teasers/icon.svg +3 -3
  4. package/components/DesignSystem/Atoms/Button.vue +86 -36
  5. package/components/DesignSystem/Atoms/Caption.vue +10 -10
  6. package/components/DesignSystem/Atoms/Container.vue +10 -6
  7. package/components/DesignSystem/Atoms/GridRow.vue +4 -3
  8. package/components/DesignSystem/Atoms/LinkListItem.vue +31 -8
  9. package/components/DesignSystem/Molecules/ButtonGroup.vue +18 -3
  10. package/components/DesignSystem/Molecules/Card.vue +86 -31
  11. package/components/DesignSystem/Molecules/IconText.vue +37 -16
  12. package/components/DesignSystem/Molecules/MediaLightbox.vue +213 -58
  13. package/components/DesignSystem/Molecules/MediaSlider.vue +88 -25
  14. package/components/DesignSystem/Molecules/Partnership.vue +40 -9
  15. package/components/DesignSystem/Molecules/Table.vue +90 -25
  16. package/components/DesignSystem/Molecules/TitleComposition.vue +15 -12
  17. package/components/DesignSystem/Organisms/ContentBlock.vue +61 -15
  18. package/components/DesignSystem/Organisms/FacetedListing.vue +170 -0
  19. package/components/DesignSystem/Organisms/FlipTeaser.vue +119 -47
  20. package/components/DesignSystem/Organisms/HeaderHero.vue +167 -0
  21. package/components/DesignSystem/Organisms/HeaderTextImage.vue +71 -0
  22. package/components/DesignSystem/Organisms/LogoElement.vue +33 -10
  23. package/components/DesignSystem/Organisms/Map.vue +11 -6
  24. package/components/DesignSystem/Organisms/SearchResults.vue +41 -0
  25. package/components/DesignSystem/Organisms/TeamElement.vue +84 -20
  26. package/components/DesignSystem/Organisms/TeaserCard.vue +87 -34
  27. package/components/DesignSystem/Organisms/Testimonial.vue +82 -12
  28. package/components/DesignSystem/Organisms/TimelineElement.vue +42 -12
  29. package/components/DesignSystem/Organisms/TwoColumnTextElement.vue +44 -9
  30. package/components/DesignSystem/Pages/Search.vue +39 -0
  31. package/components/Drupal/Breadcrumb/index.vue +16 -5
  32. package/components/Drupal/Messages/index.vue +16 -5
  33. package/components/Drupal/Webform/fragment.graphql +8 -5
  34. package/components/Drupal/Webform/index.vue +20 -9
  35. package/components/Drupal/Webform/query.graphql +18 -16
  36. package/components/Form/CheckboxInput.vue +6 -6
  37. package/components/Form/CheckboxInputs.vue +5 -5
  38. package/components/Form/FileUploadInput.vue +6 -6
  39. package/components/Form/RadioButtonsInput.vue +5 -5
  40. package/components/Form/SelectInput.vue +7 -7
  41. package/components/Form/SubmitButton.vue +1 -1
  42. package/components/Form/TextAreaInput.vue +2 -2
  43. package/components/Form/TextEmailInput.vue +2 -2
  44. package/components/Form/TextInput.vue +2 -2
  45. package/components/Form/TextPhoneInput.vue +2 -2
  46. package/components/Form/composables/useFormElement.ts +5 -5
  47. package/components/Form/utils/types.ts +8 -7
  48. package/components/Media/Icon/index.vue +10 -6
  49. package/components/Media/Image/index.vue +26 -20
  50. package/components/Media/RemoteVideo/index.vue +34 -21
  51. package/components/Media/Video/index.vue +6 -5
  52. package/components/Node/Icms/Page/Teaser/index.vue +6 -4
  53. package/components/Node/Icms/Page/index.vue +2 -2
  54. package/components/Paragraph/Button/Element/index.vue +9 -2
  55. package/components/Paragraph/CallToAction/index.vue +43 -10
  56. package/components/Paragraph/Card/Element/index.vue +2 -1
  57. package/components/Paragraph/Card/Layout/index.vue +29 -10
  58. package/components/Paragraph/Contact/index.vue +41 -12
  59. package/components/Paragraph/Downloads/index.vue +82 -33
  60. package/components/Paragraph/FAQ/Element/index.vue +41 -12
  61. package/components/Paragraph/FAQ/Layout/index.vue +47 -13
  62. package/components/Paragraph/FlipTeasers/index.vue +26 -6
  63. package/components/Paragraph/Gallery/index.vue +42 -10
  64. package/components/Paragraph/HeroImage/index.vue +62 -16
  65. package/components/Paragraph/IconText/Element/index.vue +7 -1
  66. package/components/Paragraph/IconText/Layout/index.vue +39 -12
  67. package/components/Paragraph/Introduction/index.vue +50 -15
  68. package/components/Paragraph/Logo/Element/fragment.graphql +1 -0
  69. package/components/Paragraph/Logo/Element/index.vue +7 -2
  70. package/components/Paragraph/Media/index.vue +32 -31
  71. package/components/Paragraph/Partnerships/Element/fragment.graphql +1 -0
  72. package/components/Paragraph/Partnerships/Element/index.vue +7 -0
  73. package/components/Paragraph/Partnerships/Layout/index.vue +100 -27
  74. package/components/Paragraph/SingleTestimonial/index.vue +58 -15
  75. package/components/Paragraph/Table/index.vue +32 -9
  76. package/components/Paragraph/Tabs/Element/index.vue +44 -10
  77. package/components/Paragraph/Tabs/Layout/index.vue +123 -37
  78. package/components/Paragraph/Team/Element/index.vue +18 -1
  79. package/components/Paragraph/Team/Layout/index.vue +30 -7
  80. package/components/Paragraph/Teasers/index.vue +33 -7
  81. package/components/Paragraph/Testimonial/Element/index.vue +30 -5
  82. package/components/Paragraph/Testimonial/Layout/index.vue +78 -24
  83. package/components/Paragraph/Text/index.vue +32 -10
  84. package/components/Paragraph/TextMedia/index.vue +44 -13
  85. package/components/Paragraph/Timeline/Element/index.vue +23 -7
  86. package/components/Paragraph/Timeline/Layout/index.vue +232 -67
  87. package/components/Paragraph/TwoColumnText/Element/index.vue +20 -3
  88. package/components/Paragraph/TwoColumnText/Layout/index.vue +8 -1
  89. package/components/Paragraph/iFrame/index.vue +31 -11
  90. package/components/Search/Facets/FacetDropdownUI.vue +351 -77
  91. package/components/Search/Facets/FacetedSearchUI.vue +257 -101
  92. package/components/Search/Facets/fragment.graphql +5 -1
  93. package/components/Search/Input/index.vue +125 -0
  94. package/components/Section/Footer/index.vue +170 -30
  95. package/components/Section/Header/Buttons.vue +34 -0
  96. package/components/Section/Header/DesktopMainMenu.vue +160 -0
  97. package/components/Section/Header/DesktopMainMenuDropdown.vue +170 -0
  98. package/components/Section/Header/LanguageDropdown.vue +95 -64
  99. package/components/Section/Header/LanguageLinks.vue +39 -0
  100. package/components/Section/Header/Logo.vue +23 -0
  101. package/components/Section/Header/MainButtons.vue +31 -0
  102. package/components/Section/Header/MenuIcon.vue +60 -49
  103. package/components/Section/Header/MetaButtons.vue +31 -0
  104. package/components/Section/Header/MetaMenu.vue +55 -53
  105. package/components/Section/Header/MobileMainMenu.vue +23 -0
  106. package/components/Section/Header/MobileMainMenuItem.vue +191 -0
  107. package/components/Section/Header/index.vue +182 -186
  108. package/composables/useMenu.ts +2 -2
  109. package/composables/useMobileMenuOverlayBus.ts +44 -0
  110. package/composables/useNavigationOffset.ts +2 -2
  111. package/composables/useTheme.ts +107 -0
  112. package/formkit.theme.ts +541 -586
  113. package/layouts/default.vue +7 -35
  114. package/layouts/error.vue +7 -32
  115. package/nuxt.config.ts +13 -0
  116. package/package.json +1 -1
  117. package/plugins/initData.ts +8 -5
  118. package/queries/query.initData.graphql +4 -2
  119. package/tailwind.config.ts +11 -11
  120. package/types/global.ts +1 -0
  121. package/components/Section/Header/GlobalMenu.vue +0 -335
  122. package/components/Section/Header/LanguageSwitcher.vue +0 -37
@@ -2,7 +2,9 @@
2
2
  <AccordionItem
3
3
  :key="index"
4
4
  :value="`accordion-${index + 1}`"
5
- class="border-none not-last:mb-1 [&>h3]:mb-0"
5
+ :class="
6
+ themedClass('accordionItemClass', 'not-last:mb-1 border-none [&>h3]:mb-0')
7
+ "
6
8
  v-bind="computedProps"
7
9
  >
8
10
  <AccordionTrigger
@@ -12,34 +14,61 @@
12
14
  >
13
15
  {{ question }}
14
16
  </AccordionTrigger>
15
- <AccordionContent class="p-4 pb-6 text-base" ref="contentRef">
16
- <div v-html="answer" />
17
+ <AccordionContent
18
+ :class="themedClass('accordionContentClass', 'p-4 pb-6 text-base')"
19
+ ref="contentRef"
20
+ >
21
+ <div v-html="answer" :class="themedClass('contentClass')" />
17
22
  <BlokkliField
18
23
  name="field_icms_buttons"
19
24
  :list="buttons"
20
- class="mt-6 flex flex-wrap gap-6"
21
- :class="[{ droptarget: isEditing }]"
25
+ :class="[
26
+ themedClass(
27
+ 'buttonsContainerClass',
28
+ 'mt-6 flex flex-wrap items-center gap-6',
29
+ ),
30
+ { droptarget: isEditing },
31
+ ]"
22
32
  />
23
33
  </AccordionContent>
24
34
  </AccordionItem>
25
35
  </template>
26
36
 
27
37
  <script lang="ts" setup>
38
+ import type { ComponentPublicInstance } from 'vue'
39
+ import type { ColorScheme } from '@iqual/nuxt-icms/types/global'
28
40
  import type { ParagraphIcmsFaqElementFragment } from '#graphql-operations'
29
41
  import { tv } from 'tailwind-variants'
30
42
  import { useAccordionScroll } from '@iqual/nuxt-icms/composables/useAccordionScroll'
31
- import type { ComponentPublicInstance } from 'vue'
43
+ import { useTheme } from '@iqual/nuxt-icms/composables/useTheme'
32
44
 
33
45
  defineProps<ParagraphIcmsFaqElementFragment>()
34
46
 
47
+ const themedClass = useTheme()
48
+
35
49
  const accordionTrigger = tv({
36
- base: 'items-center rounded-lg px-6 py-4 shadow-custom-small hover:no-underline gap-4 text-left text-base',
50
+ base: themedClass(
51
+ 'accordionTriggerBase',
52
+ 'items-center px-6 py-4 hover:no-underline gap-4 text-left text-base',
53
+ ),
37
54
  variants: {
38
55
  colorScheme: {
39
- none: 'bg-white text-black',
40
- dark: 'bg-gray-900 text-white',
41
- light: 'bg-white text-black',
42
- accent: 'bg-primary-700 text-white',
56
+ none: themedClass(
57
+ 'accordionVariantsColorSchemeNone',
58
+ 'bg-gray-50 text-black',
59
+ ),
60
+ dark: themedClass(
61
+ 'accordionVariantsColorSchemeDark',
62
+ 'bg-gray-900 text-white',
63
+ ),
64
+ light: themedClass(
65
+ 'accordionVariantsColorSchemeLight',
66
+ 'bg-white text-black',
67
+ ),
68
+ accent: themedClass(
69
+ 'accordionVariantsColorSchemeAccent',
70
+ 'bg-primary-700 text-white',
71
+ ),
43
72
  },
44
73
  },
45
74
  })
@@ -53,7 +82,7 @@ const handleClick = (index: number): void => {
53
82
  handleAccordionOpen()
54
83
  }
55
84
 
56
- const colorScheme = inject<string>('colorScheme')
85
+ const colorScheme = inject<ColorScheme>('colorScheme')
57
86
 
58
87
  const computedProps = computed(() => {
59
88
  if (isEditing) {
@@ -1,41 +1,71 @@
1
1
  <template>
2
- <DesignSystemAtomsContainer :spacing="spacing" :colorScheme="colorScheme">
3
- <DesignSystemAtomsGridRow>
4
- <div class="col-span-12 md:col-span-12">
2
+ <DesignSystemAtomsContainer
3
+ :spacing="spacing"
4
+ :colorScheme="colorScheme"
5
+ :class="themedClass('containerClass')"
6
+ >
7
+ <DesignSystemAtomsGridRow :class="themedClass('rowClass')">
8
+ <div
9
+ :class="themedClass('firstColumnClass', 'col-span-12 md:col-span-12')"
10
+ >
5
11
  <DesignSystemOrganismsContentBlock
6
12
  :pretitle="pretitle"
13
+ :pretitleClass="themedClass('pretitleClass')"
7
14
  :title="title"
15
+ :titleClass="themedClass('titleClass', 'mb-0')"
8
16
  :subtitle="subtitle"
17
+ :subtitleClass="themedClass('subtitleClass')"
9
18
  :titleWeight="titleWeight"
10
19
  :titleStyle="titleStyle"
11
- titleClass="mb-0"
12
20
  :colorScheme="colorScheme"
13
21
  />
14
22
  </div>
15
- <div class="col-span-12 md:col-span-5">
23
+ <div
24
+ :class="themedClass('secondColumnClass', 'col-span-12 md:col-span-5')"
25
+ >
16
26
  <DesignSystemOrganismsContentBlock
17
- :subtitle="subtitle"
18
27
  :text="text"
28
+ :textClass="themedClass('textClass')"
19
29
  :media="media"
20
- mediaClass="size-full rounded-lg overflow-hidden"
21
- mediaSliderClass="mt-0 rounded-lg overflow-hidden"
30
+ :mediaClass="themedClass('mediaClass')"
31
+ :mediaContainerClass="themedClass('mediaContainerClass', 'mt-0')"
22
32
  :colorScheme="colorScheme"
23
33
  />
24
34
  <BlokkliField
25
35
  name="field_icms_buttons"
26
36
  :list="buttons"
27
- class="mt-6 flex flex-wrap gap-6"
28
- :class="[buttonAlignment, { droptarget: isEditing }]"
37
+ :class="
38
+ cn(
39
+ themedClass(
40
+ 'buttonsContainerClass',
41
+ 'mt-6 flex flex-wrap items-center gap-6',
42
+ ),
43
+ buttonAlignment,
44
+ { droptarget: isEditing },
45
+ )
46
+ "
29
47
  />
30
48
  </div>
31
49
  <div
32
- class="relative col-span-12 mt-4 md:col-span-6 md:col-start-7 md:mt-0"
50
+ :class="
51
+ themedClass(
52
+ 'thirdColumnClass',
53
+ 'relative col-span-12 mt-4 md:col-span-6 md:col-start-7 md:mt-0',
54
+ )
55
+ "
33
56
  >
34
- <Accordion :default-value="defaultValue" :collapsible="true">
57
+ <Accordion
58
+ :default-value="defaultValue"
59
+ :collapsible="true"
60
+ :class="themedClass('accordionClass')"
61
+ >
35
62
  <BlokkliField
36
63
  name="field_icms_faq_elements"
37
64
  :list="faqElements"
38
- :class="{ droptarget: isEditing }"
65
+ :class="[
66
+ themedClass('accordionsContainerClass'),
67
+ { droptarget: isEditing },
68
+ ]"
39
69
  />
40
70
  </Accordion>
41
71
  </div>
@@ -45,9 +75,13 @@
45
75
 
46
76
  <script lang="ts" setup>
47
77
  import type { ParagraphIcmsLayoutFaqFragment } from '#graphql-operations'
78
+ import { useTheme } from '@iqual/nuxt-icms/composables/useTheme'
79
+ import cn from '@iqual/nuxt-icms/composables/useCn'
48
80
 
49
81
  const props = defineProps<ParagraphIcmsLayoutFaqFragment>()
50
82
 
83
+ const themedClass = useTheme()
84
+
51
85
  const defaultValue = computed(() => {
52
86
  if (!isEditing) {
53
87
  return 'accordion-1'
@@ -1,20 +1,35 @@
1
1
  <template>
2
- <DesignSystemAtomsContainer :colorScheme="colorScheme" :spacing="spacing">
3
- <DesignSystemAtomsGridRow>
4
- <div class="col-span-12 md:col-span-12">
2
+ <DesignSystemAtomsContainer
3
+ :colorScheme="colorScheme"
4
+ :spacing="spacing"
5
+ :class="themedClass('containerClass')"
6
+ >
7
+ <DesignSystemAtomsGridRow :class="themedClass('firstRowClass')">
8
+ <div
9
+ :class="
10
+ themedClass('firstRowFirstColumnClass', 'col-span-12 md:col-span-12')
11
+ "
12
+ >
5
13
  <DesignSystemOrganismsContentBlock
6
14
  :pretitle="pretitle"
15
+ :pretitleClass="themedClass('pretitleClass')"
7
16
  :title="title"
17
+ :titleClass="themedClass('titleClass', 'mb-0')"
8
18
  :titleWeight="titleWeight"
9
19
  :titleStyle="titleStyle"
10
- titleClass="mb-0"
11
20
  :colorScheme="colorScheme"
12
21
  />
13
22
  </div>
14
- <div class="col-span-12 md:col-span-9">
23
+ <div
24
+ :class="
25
+ themedClass('firstRowSecondColumnClass', 'col-span-12 md:col-span-9')
26
+ "
27
+ >
15
28
  <DesignSystemOrganismsContentBlock
16
29
  :subtitle="subtitle"
30
+ :subtitleClass="themedClass('subtitleClass')"
17
31
  :text="text"
32
+ :textClass="themedClass('textClass')"
18
33
  :titleWeight="titleWeight"
19
34
  :titleStyle="titleStyle"
20
35
  :colorScheme="colorScheme"
@@ -22,7 +37,9 @@
22
37
  </div>
23
38
  </DesignSystemAtomsGridRow>
24
39
 
25
- <DesignSystemAtomsGridRow class="mt-10 md:mt-20">
40
+ <DesignSystemAtomsGridRow
41
+ :class="themedClass('secondRowClass', 'mt-10 md:mt-20')"
42
+ >
26
43
  <DesignSystemOrganismsFlipTeaser
27
44
  v-for="flipTeaser in flipTeasers"
28
45
  :image="flipTeaser?.image || flipTeaser?.mainImage"
@@ -40,9 +57,12 @@
40
57
 
41
58
  <script lang="ts" setup>
42
59
  import type { ParagraphIcmsLayoutFlipTeasersFragment } from '#graphql-operations'
60
+ import { useTheme } from '@iqual/nuxt-icms/composables/useTheme'
43
61
 
44
62
  const props = defineProps<ParagraphIcmsLayoutFlipTeasersFragment>()
45
63
 
64
+ const themedClass = useTheme()
65
+
46
66
  const { options, parentType } = useAttrs().blokkliData
47
67
 
48
68
  const colorScheme = computed(() => {
@@ -1,42 +1,71 @@
1
1
  <template>
2
- <DesignSystemAtomsContainer :colorScheme="colorScheme" :spacing="spacing">
3
- <DesignSystemAtomsGridRow>
4
- <div class="col-span-12 md:col-span-12">
2
+ <DesignSystemAtomsContainer
3
+ :colorScheme="colorScheme"
4
+ :spacing="spacing"
5
+ :class="themedClass('containerClass')"
6
+ >
7
+ <DesignSystemAtomsGridRow :class="themedClass('firstRowClass')">
8
+ <div
9
+ :class="
10
+ themedClass('firstRowFirstColumnClass', 'col-span-12 md:col-span-12')
11
+ "
12
+ >
5
13
  <DesignSystemOrganismsContentBlock
6
14
  :pretitle="pretitle"
15
+ :pretitleClass="themedClass('pretitleClass')"
7
16
  :title="title"
17
+ :titleClass="themedClass('titleClass', 'mb-0')"
8
18
  :titleWeight="titleWeight"
9
19
  :titleStyle="titleStyle"
10
- titleClass="mb-0"
11
20
  :colorScheme="colorScheme"
12
21
  />
13
22
  </div>
14
- <div class="col-span-12 md:col-span-9">
23
+ <div
24
+ :class="
25
+ themedClass('firstRowSecondColumnClass', 'col-span-12 md:col-span-9')
26
+ "
27
+ >
15
28
  <DesignSystemOrganismsContentBlock
16
29
  :subtitle="subtitle"
30
+ :subtitleClass="themedClass('subtitleClass')"
17
31
  :text="text"
32
+ :textClass="themedClass('textClass')"
18
33
  :colorScheme="colorScheme"
19
34
  />
20
35
  </div>
21
36
  </DesignSystemAtomsGridRow>
22
37
 
23
- <DesignSystemAtomsGridRow v-if="media?.length" class="mt-10 md:mt-20">
38
+ <DesignSystemAtomsGridRow
39
+ v-if="media?.length"
40
+ :class="themedClass('secondRowClass', 'mt-10 md:mt-20')"
41
+ >
24
42
  <div
25
43
  v-for="(image, index) in media"
26
44
  :key="index"
27
- class="gallery-item col-span-12 aspect-square overflow-hidden rounded-lg md:col-span-6 lg:col-span-3"
45
+ :class="[
46
+ 'gallery-item',
47
+ themedClass(
48
+ 'galleryItemClass',
49
+ 'col-span-12 aspect-square md:col-span-6 lg:col-span-3',
50
+ ),
51
+ ]"
28
52
  @click="openLightbox(index)"
29
53
  >
30
54
  <MediaImage
31
55
  v-if="image"
32
56
  :media="image"
33
57
  imageAspectRatios="1/1"
34
- imageSizes="xs:100vw sm-100vw md:320px lg:400px"
35
- mediaClass="size-full cursor-pointer object-cover object-center"
58
+ imageSizes="xs:100vw sm:100vw md:320px lg:400px"
59
+ :mediaClass="themedClass('mediaClass', 'w-full cursor-pointer')"
60
+ :figcaptionClass="themedClass('figcaptionClass')"
61
+ :elementClass="themedClass('elementClass')"
36
62
  />
37
63
  </div>
64
+
38
65
  <DesignSystemMoleculesMediaLightbox
39
- :media-objects="(media?.filter((item): item is MediaFragment => Boolean(item)) || [])"
66
+ :media-objects="
67
+ media?.filter((item): item is MediaFragment => Boolean(item)) || []
68
+ "
40
69
  :is-open="isOpen"
41
70
  :current-index="currentIndex"
42
71
  :captions="captions"
@@ -50,12 +79,15 @@
50
79
  <script lang="ts" setup>
51
80
  import type { ParagraphIcmsLayoutGalleryFragment } from '#graphql-operations'
52
81
  import type { MediaFragment } from '#graphql-operations'
82
+ import { useTheme } from '@iqual/nuxt-icms/composables/useTheme'
53
83
  import { useMediaLightbox } from '@iqual/nuxt-icms/composables/useMediaLightbox'
54
84
 
55
85
  const { options } = useAttrs().blokkliData as any
56
86
 
57
87
  const props = defineProps<ParagraphIcmsLayoutGalleryFragment>()
58
88
 
89
+ const themedClass = useTheme()
90
+
59
91
  const {
60
92
  isOpen,
61
93
  currentIndex,
@@ -1,22 +1,29 @@
1
1
  <template>
2
2
  <DesignSystemAtomsContainer
3
3
  :spacing="{ top: 'none', bottom: 'none' }"
4
- :class="containerClassList"
5
- class="relative flex min-h-[400] items-center md:min-h-[700px]"
4
+ :class="
5
+ cn(
6
+ themedClass(
7
+ 'containerClass',
8
+ 'relative flex min-h-[400px] items-center md:min-h-[700px]',
9
+ ),
10
+ containerClassList,
11
+ )
12
+ "
6
13
  >
7
14
  <!-- Overlay -->
8
15
  <div
9
16
  v-if="options.colorMode !== 'none'"
10
- class="absolute inset-0 z-10"
11
- :class="overlayClass"
17
+ :class="
18
+ cn(themedClass('overlayClass', 'absolute inset-0 z-10'), overlayClass)
19
+ "
12
20
  />
13
21
 
14
22
  <!-- Image/video wrapper -->
15
- <div class="absolute inset-0">
23
+ <div :class="themedClass('mediaContainerClass', 'absolute inset-0')">
16
24
  <Media
17
25
  v-if="medium"
18
26
  :media="medium"
19
- mediaClass="size-full object-cover"
20
27
  imageAspectRatios="xs:1/1 md:16/9"
21
28
  imageSizes="xs:100vw sm:100vw md:100vw lg:100vw xl:100vw xxl:100vw"
22
29
  imageLoading="eager"
@@ -24,34 +31,54 @@
24
31
  videoAutoplay
25
32
  videoMuted
26
33
  videoLoop
34
+ :mediaClass="themedClass('mediaClass')"
35
+ :elementClass="
36
+ themedClass('elementClass', 'size-full object-cover object-center')
37
+ "
38
+ :figcaptionClass="themedClass('figcaptionClass')"
27
39
  />
28
- <div class="absolute inset-0" />
29
40
  </div>
30
41
 
31
42
  <!-- Text row -->
32
43
  <DesignSystemAtomsGridRow
33
44
  v-if="pretitle || title || subtitle"
34
- class="relative z-10 px-4 py-12 md:px-12 md:py-32"
45
+ :class="
46
+ themedClass('rowClass', 'relative z-10 px-4 py-12 md:px-12 md:py-32')
47
+ "
35
48
  >
36
- <div class="col-span-12 md:col-span-6" :class="columnClassList">
49
+ <div
50
+ :class="
51
+ cn(
52
+ themedClass('columnClass', 'col-span-12 md:col-span-6'),
53
+ columnClassList,
54
+ )
55
+ "
56
+ >
37
57
  <DesignSystemOrganismsContentBlock
38
58
  :pretitle="pretitle"
39
- :pretitleClass="textShadow"
59
+ :pretitleClass="cn(themedClass('pretitleClass'), textShadow)"
40
60
  :title="title"
41
61
  :titleWeight="titleWeight"
42
62
  :titleStyle="titleStyle"
43
- :titleClass="textShadow"
63
+ :titleClass="cn(themedClass('titleClass'), textShadow)"
44
64
  :subtitle="subtitle"
45
- :subtitleClass="textShadow"
65
+ :subtitleClass="cn(themedClass('subtitleClass'), textShadow)"
46
66
  :text="text"
47
- :textClass="textShadow"
67
+ :textClass="cn(themedClass('textClass'), textShadow)"
48
68
  />
49
-
50
69
  <BlokkliField
51
70
  name="field_icms_buttons"
52
71
  :list="buttons"
53
- class="mt-6 flex flex-wrap gap-6"
54
- :class="[buttonAlignment, { droptarget: isEditing }]"
72
+ :class="
73
+ cn(
74
+ themedClass(
75
+ 'buttonsContainerClass',
76
+ 'mt-6 flex flex-wrap items-center gap-6',
77
+ ),
78
+ buttonAlignment,
79
+ { droptarget: isEditing },
80
+ )
81
+ "
55
82
  />
56
83
  </div>
57
84
  </DesignSystemAtomsGridRow>
@@ -60,9 +87,13 @@
60
87
 
61
88
  <script lang="ts" setup>
62
89
  import type { ParagraphIcmsLayoutHeroImageFragment } from '#graphql-operations'
90
+ import cn from '@iqual/nuxt-icms/composables/useCn'
91
+ import { useTheme } from '@iqual/nuxt-icms/composables/useTheme'
63
92
 
64
93
  defineProps<ParagraphIcmsLayoutHeroImageFragment>()
65
94
 
95
+ const themedClass = useTheme()
96
+
66
97
  const prefetch = provide('prefetch', true)
67
98
 
68
99
  const { options, isEditing } = useAttrs().blokkliData
@@ -152,5 +183,20 @@ const buttonAlignment = computed(() => {
152
183
  return 'justify-start'
153
184
  }
154
185
  })
186
+
187
+ const elementClass = computed(() => {
188
+ const classList = ['size-full object-cover']
189
+ if (options.value.imageAlignment === 'top') {
190
+ classList.push('object-top')
191
+ }
192
+ if (options.value.imageAlignment === 'center') {
193
+ classList.push('object-center')
194
+ }
195
+ if (options.value.imageAlignment === 'bottom') {
196
+ classList.push('object-bottom')
197
+ }
198
+ return classList.join(' ')
199
+ })
200
+
155
201
  provide('colorScheme', options.value.colorMode ?? 'none')
156
202
  </script>
@@ -1,8 +1,10 @@
1
1
  <template>
2
2
  <DesignSystemMoleculesIconText
3
3
  :title="title"
4
+ :titleClass="themedClass('titleClass')"
4
5
  :titleWeight="titleWeight"
5
6
  :text="text"
7
+ :textClass="themedClass('textClass')"
6
8
  :icon="icon"
7
9
  :colorScheme="colorScheme"
8
10
  />
@@ -10,9 +12,13 @@
10
12
 
11
13
  <script lang="ts" setup>
12
14
  import type { ParagraphIcmsIconTextElementFragment } from '#graphql-operations'
15
+ import type { ColorScheme } from '@iqual/nuxt-icms/types/global'
16
+ import { useTheme } from '@iqual/nuxt-icms/composables/useTheme'
13
17
 
14
18
  defineProps<ParagraphIcmsIconTextElementFragment>()
15
19
 
16
- const colorScheme = inject<string>('colorScheme')
20
+ const themedClass = useTheme()
21
+
22
+ const colorScheme = inject<ColorScheme>('colorScheme')
17
23
  const titleWeight = inject<string>('titleWeight')
18
24
  </script>
@@ -1,39 +1,62 @@
1
1
  <template>
2
- <DesignSystemAtomsContainer :colorScheme="colorScheme" :spacing="spacing">
3
- <DesignSystemAtomsGridRow>
4
- <div class="col-span-12 md:col-span-12">
2
+ <DesignSystemAtomsContainer
3
+ :colorScheme="colorScheme"
4
+ :spacing="spacing"
5
+ :class="themedClass('containerClass')"
6
+ >
7
+ <DesignSystemAtomsGridRow :class="themedClass('rowClass')">
8
+ <div
9
+ :class="themedClass('firstColumnClass', 'col-span-12 md:col-span-12')"
10
+ >
5
11
  <DesignSystemOrganismsContentBlock
6
12
  :pretitle="pretitle"
13
+ :pretitleClass="themedClass('pretitleClass')"
7
14
  :title="title"
15
+ :titleClass="themedClass('titleClass', 'mb-0')"
8
16
  :subtitle="subtitle"
17
+ :subtitleClass="themedClass('subtitleClass')"
9
18
  :titleWeight="titleWeight"
10
19
  :titleStyle="titleStyle"
11
- titleClass="mb-0"
12
20
  :colorScheme="colorScheme"
13
21
  />
14
22
  </div>
15
- <div class="col-span-12 md:col-span-5">
23
+ <div
24
+ :class="themedClass('secondColumnClass', 'col-span-12 md:col-span-5')"
25
+ >
16
26
  <DesignSystemOrganismsContentBlock
17
- :subtitle="subtitle"
18
27
  :text="text"
28
+ :textClass="themedClass('textClass')"
19
29
  :media="media"
20
- mediaClass="size-full rounded-lg overflow-hidden"
21
- mediaSliderClass="mt-0 rounded-lg overflow-hidden"
30
+ :mediaClass="themedClass('mediaClass')"
31
+ :mediaContainerClass="themedClass('mediaContainerClass', 'mt-0')"
22
32
  :colorScheme="colorScheme"
23
33
  />
24
34
 
25
35
  <BlokkliField
26
36
  name="field_icms_buttons"
27
37
  :list="buttons"
28
- class="mt-6 flex flex-wrap gap-6"
29
- :class="[buttonAlignment, { droptarget: isEditing }]"
38
+ :class="
39
+ cn(
40
+ themedClass(
41
+ 'buttonsContainerClass',
42
+ 'mt-6 flex flex-wrap items-center gap-6',
43
+ ),
44
+ buttonAlignment,
45
+ { droptarget: isEditing },
46
+ )
47
+ "
30
48
  />
31
49
  </div>
32
50
  <BlokkliField
33
51
  name="field_icms_icon_text_elements"
34
52
  :list="iconTextElements"
35
- class="col-span-12 mt-4 flex flex-col gap-6 md:col-span-6 md:col-start-7 md:mt-0"
36
- :class="{ droptarget: isEditing }"
53
+ :class="[
54
+ themedClass(
55
+ 'iconTextElementsContainerClass',
56
+ 'col-span-12 mt-4 flex flex-col gap-6 md:col-span-6 md:col-start-7 md:mt-0',
57
+ ),
58
+ { droptarget: isEditing },
59
+ ]"
37
60
  />
38
61
  </DesignSystemAtomsGridRow>
39
62
  </DesignSystemAtomsContainer>
@@ -41,9 +64,13 @@
41
64
 
42
65
  <script lang="ts" setup>
43
66
  import type { ParagraphIcmsLayoutTextcolIconlistFragment } from '#graphql-operations'
67
+ import cn from '@iqual/nuxt-icms/composables/useCn'
68
+ import { useTheme } from '@iqual/nuxt-icms/composables/useTheme'
44
69
 
45
70
  const props = defineProps<ParagraphIcmsLayoutTextcolIconlistFragment>()
46
71
 
72
+ const themedClass = useTheme()
73
+
47
74
  const { options, isEditing } = useAttrs().blokkliData
48
75
 
49
76
  const colorScheme = computed(() => {