@ndla/ui 56.0.55-alpha.0 → 56.0.56-alpha.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.
@@ -324,7 +324,8 @@
324
324
  "gridColumnGap]___[value:medium",
325
325
  "backgroundColor]___[value:background.subtle",
326
326
  "gridTemplateColumns]___[value:repeat(2, minmax(0, 1fr))",
327
- "marginTop]___[value:auto]___[cond:& > [data-embed-type='pitch']<___>& > :last-child",
327
+ "height]___[value:100%]___[cond:& :not(div[data-parallax-cell='true']) > div[data-embed-type='pitch']",
328
+ "marginTop]___[value:auto]___[cond:& :not(div[data-parallax-cell='true']) > div[data-embed-type='pitch']<___>& > :last-child",
328
329
  "gridTemplateColumns]___[value:repeat(1, minmax(0, 1fr))]___[cond:tabletDown",
329
330
  "gridTemplateColumns]___[value:repeat(2, minmax(0, 1fr))]___[cond:tabletToDesktop",
330
331
  "display]___[value:flex]___[cond:tabletToDesktop<___>& > div:nth-child(3):last-child",
package/dist/styles.css CHANGED
@@ -1063,6 +1063,10 @@
1063
1063
  background: var(--colors-surface-brand-1-subtle);
1064
1064
  }
1065
1065
 
1066
+ .\[\&_\:not\(div\[data-parallax-cell\=\'true\'\]\)_\>_div\[data-embed-type\=\'pitch\'\]\]\:h_100\% :not(div[data-parallax-cell='true']) > div[data-embed-type='pitch'] {
1067
+ height: 100%;
1068
+ }
1069
+
1066
1070
  .\[\&_\>_div\]\:pos_sticky > div {
1067
1071
  position: sticky;
1068
1072
  }
@@ -1258,7 +1262,7 @@
1258
1262
  font-weight: var(--font-weights-bold);
1259
1263
  }
1260
1264
 
1261
- .\[\&_\>_\[data-embed-type\=\'pitch\'\]\]\:\[\&_\>_\:last-child\]\:mt_auto > [data-embed-type='pitch'] > :last-child {
1265
+ .\[\&_\:not\(div\[data-parallax-cell\=\'true\'\]\)_\>_div\[data-embed-type\=\'pitch\'\]\]\:\[\&_\>_\:last-child\]\:mt_auto :not(div[data-parallax-cell='true']) > div[data-embed-type='pitch'] > :last-child {
1262
1266
  margin-top: auto;
1263
1267
  }
1264
1268
 
package/es/Grid/Grid.js CHANGED
@@ -19,7 +19,8 @@ const GridContainer = styled("div", {
19
19
  backgroundColor: "background.subtle",
20
20
  minWidth: "surface.xxsmall",
21
21
  gridTemplateColumns: "repeat(2, minmax(0, 1fr))",
22
- "& > [data-embed-type='pitch']": {
22
+ "& :not(div[data-parallax-cell='true']) > div[data-embed-type='pitch']": {
23
+ height: "100%",
23
24
  "& > :last-child": {
24
25
  marginTop: "auto"
25
26
  }
package/es/Pitch/Pitch.js CHANGED
@@ -73,7 +73,7 @@ export const Pitch = _ref => {
73
73
  variant: "rounded",
74
74
  src: metaImage.url,
75
75
  alt: metaImage.alt,
76
- sizes: "180px",
76
+ sizes: "480px",
77
77
  fallbackWidth: 300,
78
78
  width: 550,
79
79
  height: 310
package/lib/Grid/Grid.js CHANGED
@@ -25,7 +25,8 @@ const GridContainer = (0, _jsx2.styled)("div", {
25
25
  backgroundColor: "background.subtle",
26
26
  minWidth: "surface.xxsmall",
27
27
  gridTemplateColumns: "repeat(2, minmax(0, 1fr))",
28
- "& > [data-embed-type='pitch']": {
28
+ "& :not(div[data-parallax-cell='true']) > div[data-embed-type='pitch']": {
29
+ height: "100%",
29
30
  "& > :last-child": {
30
31
  marginTop: "auto"
31
32
  }
@@ -80,7 +80,7 @@ const Pitch = _ref => {
80
80
  variant: "rounded",
81
81
  src: metaImage.url,
82
82
  alt: metaImage.alt,
83
- sizes: "180px",
83
+ sizes: "480px",
84
84
  fallbackWidth: 300,
85
85
  width: 550,
86
86
  height: 310
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ndla/ui",
3
- "version": "56.0.55-alpha.0",
3
+ "version": "56.0.56-alpha.0",
4
4
  "description": "UI component library for NDLA",
5
5
  "license": "GPL-3.0",
6
6
  "main": "lib/index.js",
@@ -58,5 +58,5 @@
58
58
  "publishConfig": {
59
59
  "access": "public"
60
60
  },
61
- "gitHead": "61d88c7c1bbad19fd1d94f13c0088b0684f95ff6"
61
+ "gitHead": "49af42aa58dfaf274b6796f4822e09572d91dc9b"
62
62
  }
package/src/Grid/Grid.tsx CHANGED
@@ -20,7 +20,9 @@ const GridContainer = styled("div", {
20
20
  backgroundColor: "background.subtle",
21
21
  minWidth: "surface.xxsmall",
22
22
  gridTemplateColumns: "repeat(2, minmax(0, 1fr))",
23
- "& > [data-embed-type='pitch']": {
23
+
24
+ "& :not(div[data-parallax-cell='true']) > div[data-embed-type='pitch']": {
25
+ height: "100%",
24
26
  "& > :last-child": {
25
27
  marginTop: "auto",
26
28
  },
@@ -44,8 +44,12 @@ export default {
44
44
  export const Default: StoryFn<typeof Pitch> = ({ ...args }) => {
45
45
  return (
46
46
  <Grid columns="2" background="transparent">
47
- <Pitch {...args} />
48
- <Pitch {...args} description="Kortere beskrivelse" />
47
+ <div data-type="grid-cell" data-parallax-cell="false">
48
+ <Pitch {...args} />
49
+ </div>
50
+ <div data-type="grid-cell" data-parallax-cell="false">
51
+ <Pitch {...args} description="Kortere beskrivelse" />
52
+ </div>
49
53
  </Grid>
50
54
  );
51
55
  };
@@ -72,7 +72,7 @@ export const Pitch = ({ title, url, metaImage, path, description }: Props) => {
72
72
  variant="rounded"
73
73
  src={metaImage.url}
74
74
  alt={metaImage.alt}
75
- sizes="180px"
75
+ sizes="480px"
76
76
  fallbackWidth={300}
77
77
  width={550}
78
78
  height={310}