Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support for background size #95

Closed
mgierlasinski opened this issue Jun 26, 2020 · 0 comments · Fixed by #112
Closed

Support for background size #95

mgierlasinski opened this issue Jun 26, 2020 · 0 comments · Fixed by #112
Assignees
Labels
🛠️ enhancement New feature or request
Milestone

Comments

@mgierlasinski
Copy link
Owner

Currently GradientView renders it's IGradientSource by filling all available space. To handle complex css gradients we should handle css property background-size which says render me using specific rectangle, not whole space. As an initial implementation, if GradientSize < available space, it should be tiled. Later, we can consider adding support for GradientPosition and GradientRepeat (analogical to css: background-position and background-repeat).

API changes

GradientView control

public Size GradientSize { get; set; }

GradientView CSS

background: linear-gradient(...); // no changes, maps to GradientSource
background-size: 100px 100px; // new property, maps to GradientSize 
@mgierlasinski mgierlasinski added the 🛠️ enhancement New feature or request label Jun 26, 2020
@mgierlasinski mgierlasinski added this to the v1.1.1 milestone Jun 26, 2020
@mgierlasinski mgierlasinski self-assigned this Jun 26, 2020
@mgierlasinski mgierlasinski added this to To do in Magic Gradients via automation Jun 26, 2020
@bbenetskyy bbenetskyy linked a pull request Jun 27, 2020 that will close this issue
@bbenetskyy bbenetskyy removed a link to a pull request Jun 27, 2020
@mgierlasinski mgierlasinski modified the milestones: v1.1.1, v1.2.0 Aug 11, 2020
@mgierlasinski mgierlasinski moved this from To do to In progress in Magic Gradients Sep 4, 2020
Magic Gradients automation moved this from In progress to Done Sep 9, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🛠️ enhancement New feature or request
Projects
Development

Successfully merging a pull request may close this issue.

1 participant