Skip to content

Allow property values to be arrays to represent multiple declarations of the same property #177

@andycoles

Description

@andycoles

Problem Statement

Rainbow Sprinkles currently doesn't accept values as an array when declaring CSS properties.

This could be useful when using the graceful degradation technique for legacy browser fallbacks, similar to what vanilla-extract has outlined here: https://vanilla-extract.style/documentation/styling/#fallback-styles.

Proposed Solution

const { className, style, otherProps } = rainbowSprinkles({ overflow: ['auto', 'overlay'], });

Additional Context

Other instances where it is useful to have this supported:
https://stackoverflow.com/questions/44793453/how-do-i-add-a-top-and-bottom-shadow-while-scrolling-but-only-when-needed. This is where I landed in my investigation and this is the actual particular use case that I am solving for. Please suggest alternatives if any are known as a possible stop gap. Thank you.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions