@carbon/ibmdotcom-styles 2.23.0 → 2.25.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.
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@carbon/ibmdotcom-styles",
3
3
  "description": "Carbon for IBM.com Styles",
4
- "version": "2.23.0",
4
+ "version": "2.25.0",
5
5
  "license": "Apache-2.0",
6
6
  "main": "dist/ibm-dotcom-styles.min.css",
7
7
  "module": "src/scss",
@@ -48,5 +48,5 @@
48
48
  "sass": "~1.84.0",
49
49
  "sass-loader": "^13.0.0"
50
50
  },
51
- "gitHead": "9604f645e0c57f759fa698ef64a2504b0b244c52"
51
+ "gitHead": "f3f2a1b80455f6300ce092c729bae016442259ff"
52
52
  }
@@ -69,6 +69,16 @@
69
69
  }
70
70
  }
71
71
 
72
+ .#{$prefix}--background-media--gradient--right-to-left {
73
+ @include breakpoint(lg) {
74
+ background-image: linear-gradient(
75
+ to left,
76
+ $background 25%,
77
+ rgba(255, 255, 255, 0) 75%
78
+ );
79
+ }
80
+ }
81
+
72
82
  .#{$prefix}--background-media--gradient--top-to-bottom {
73
83
  @include breakpoint(lg) {
74
84
  background-image: linear-gradient(
@@ -14,6 +14,7 @@
14
14
  @use '@carbon/styles/scss/themes' as *;
15
15
  @use '@carbon/styles/scss/type' as *;
16
16
  @use '@carbon/styles/scss/utilities/convert' as *;
17
+ @use '@carbon/ibmdotcom-styles/scss/globals/scroll-snap' as *;
17
18
  @use '../../globals/utils/flex-grid' as *;
18
19
  @use '../../globals/vars' as *;
19
20
  @use '../../globals/imports' as *;
@@ -243,6 +244,53 @@
243
244
  }
244
245
  }
245
246
 
247
+ // Mobile horizontal scroll snap behavior
248
+ :host(#{$c4d-prefix}-card-group).inside-block-cards:not(
249
+ .media-type-block-cards__logo
250
+ ) {
251
+ $gutter: 1rem;
252
+ $gap: 1rem;
253
+
254
+ @include breakpoint-down('md') {
255
+ @include scroll-snap-container();
256
+
257
+ display: flex;
258
+ gap: $gap;
259
+ padding-inline: $gutter;
260
+
261
+ > ::slotted(a) {
262
+ /* stylelint-disable-next-line declaration-no-important */
263
+ display: grid !important;
264
+ box-sizing: border-box;
265
+ flex-basis: clamp(220px, 65vw, 400px);
266
+ flex-shrink: 0;
267
+ align-content: start;
268
+ block-size: auto;
269
+
270
+ // override web component internal padding and rely on gap instead
271
+ padding-inline: 0;
272
+
273
+ scroll-margin: $gutter;
274
+ scroll-snap-align: start;
275
+ }
276
+
277
+ > ::slotted(#{$c4d-prefix}-card-group-item) {
278
+ display: grid;
279
+ box-sizing: border-box;
280
+ flex-basis: clamp(220px, 65vw, 400px);
281
+ flex-shrink: 0;
282
+ align-content: start;
283
+ block-size: auto;
284
+
285
+ // // override web component internal padding and rely on gap instead
286
+ padding-inline: 0;
287
+
288
+ scroll-margin: $gutter;
289
+ scroll-snap-align: start;
290
+ }
291
+ }
292
+ }
293
+
246
294
  // Print styles
247
295
  @media print {
248
296
  :host(#{$c4d-prefix}-card-group) {
@@ -1,7 +1,7 @@
1
1
  /**
2
2
  * @license
3
3
  *
4
- * Copyright IBM Corp. 2020, 2024
4
+ * Copyright IBM Corp. 2020, 2025
5
5
  *
6
6
  * This source code is licensed under the Apache-2.0 license found in the
7
7
  * LICENSE file in the root directory of this source tree.
@@ -106,6 +106,19 @@
106
106
  }
107
107
  }
108
108
 
109
+ :host(:dir(rtl)) {
110
+ ::slotted([slot='heading']) {
111
+ margin-right: 1rem;
112
+ }
113
+
114
+ ::slotted([slot='action']) {
115
+ //important needed because <a slot="action" style="display: contents;"> in AEM has an inline style
116
+ /* stylelint-disable declaration-no-important */
117
+ display: block !important;
118
+ margin-right: 1rem !important;
119
+ }
120
+ }
121
+
109
122
  // Print styles
110
123
  @media print {
111
124
  .#{$prefix}--card-section-offset__content,