@contentful/experiences-core 1.31.0 → 1.31.1-dev-20250218T1728-50b0be5.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/dist/index.js +1 -3
- package/dist/index.js.map +1 -1
- package/dist/utils/breakpoints.d.ts +1 -1
- package/package.json +3 -3
package/dist/index.js
CHANGED
|
@@ -2627,7 +2627,7 @@ const builtInStylesWithDesignTokens = [
|
|
|
2627
2627
|
const isValidBreakpointValue = (value) => {
|
|
2628
2628
|
return value !== undefined && value !== null && value !== '';
|
|
2629
2629
|
};
|
|
2630
|
-
const getValueForBreakpoint = (valuesByBreakpoint, breakpoints, activeBreakpointIndex, variableName, resolveDesignTokens = true) => {
|
|
2630
|
+
const getValueForBreakpoint = (valuesByBreakpoint, breakpoints, activeBreakpointIndex, fallbackBreakpointIndex, variableName, resolveDesignTokens = true) => {
|
|
2631
2631
|
const eventuallyResolveDesignTokens = (value) => {
|
|
2632
2632
|
// For some built-in design properties, we support design tokens
|
|
2633
2633
|
if (builtInStylesWithDesignTokens.includes(variableName)) {
|
|
@@ -2648,8 +2648,6 @@ const getValueForBreakpoint = (valuesByBreakpoint, breakpoints, activeBreakpoint
|
|
|
2648
2648
|
return valuesByBreakpoint[breakpointId];
|
|
2649
2649
|
}
|
|
2650
2650
|
}
|
|
2651
|
-
// If no breakpoint matched, we search and apply the fallback breakpoint
|
|
2652
|
-
const fallbackBreakpointIndex = getFallbackBreakpointIndex(breakpoints);
|
|
2653
2651
|
const fallbackBreakpointId = breakpoints[fallbackBreakpointIndex]?.id;
|
|
2654
2652
|
if (isValidBreakpointValue(valuesByBreakpoint[fallbackBreakpointId])) {
|
|
2655
2653
|
if (resolveDesignTokens) {
|