Skip to content

Support multiple values for background-clip #2441

Description

@stalniy

Issue type
Feature request

Description of new feature

Allow to specify multiple values for background-clip property, so some background images will be clipped and others not

Motivation for new feature

I want to render an background image outside the node. Documentation says that I need to disable background-clip but this doesn't work my case, well partially.

What I want is to specify multiple background images, clip the first image but DON'T clip the 2nd

Additional

I already tried to do this and it works, requires simple changes in 2 places:

So, if you approve, I will send PR.

Activity

  1. maxkfranz commented on Jun 20, 2019

    @maxkfranz
    Member

    So, if you approve, I will send PR.

    OK, as long as it doesn't break compatibility. I think multiple: true properties allow a single value to be used as an implicit array of length 1, so it should probably be OK.

  2. maxkfranz commented on Jun 20, 2019

    @maxkfranz
    Member

    You can check how other bg image properties are used. I think it may be if only one value is specified, then the same value is used for all.

  3. stalniy commented on Jun 20, 2019

    @stalniy
    ContributorAuthor

    Done.

    Adding an example of how this looks, so it's easier to understand the purpose. I have a regular image which is requested by HTTP (background-clip is applied to it) and svg image (black circle) which is base64 encoded (background-clip is not applied to it):

    example

  4. added this to the 3.8.0 milestone on Jun 20, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions