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

@shape, @rectangle and @polygon #83

Open
Mouvedia opened this issue Nov 11, 2012 · 0 comments
Open

@shape, @rectangle and @polygon #83

Mouvedia opened this issue Nov 11, 2012 · 0 comments
Labels

Comments

@Mouvedia
Copy link
Member

@shape
    x: <number>;
    y: <number>;
    width: <number> | content;
    height: <number> | content;
    @rectangle
               [<number>]
               top: @corner | [<number>];
               bottom: @corner | [<number>];
               left: @corner | [<number>];
               right: @corner | [<number>];
               topLeft: @corner | [<number>]; (1)
               topRight: @corner | [<number>]; (2)
               bottomLeft: @corner | [<number>]; (3)
               bottomRight: @corner | [<number>]; (4)
                            @corner
                                           size: <number>; (1)
                                           type: (round) | bevel | straight; (2)
               corners:
                            [<number>]
                            (@round)
                                           corners: <number>, <number>, <number>, <number>;
                                           top: <number>;
                                           bottom: <number>;
                                           left: <number>;
                                           right: <number>;
                                           topLeft: <number>; (1)
                                           topRight: <number>; (2)
                                           bottomLeft: <number>; (3)
                                           bottomRight: <number>; (4)
                            @bevel
                                           corners: <number>, <number>, <number>, <number>;
                                           top: <number>;
                                           bottom: <number>;
                                           left: <number>;
                                           right: <number>;
                                           topLeft: <number>;
                                           topRight: <number>;
                                           bottomLeft: <number>;
                                           bottomRight: <number>;
                            @straight
                                           corners: <number>, <number>, <number>, <number>;¹
                                           top: <number>;¹
                                           bottom: <number>;¹
                                           left: <number>;¹
                                           right: <number>;¹
                                           topLeft: <number>¹
                                           topRight: <number>;¹
                                           bottomLeft: <number>;¹
                                           bottomRight: <number>;¹
    @polygon
               sides: <N>;
               angle: -360–360;
               corners:
                            (@straight)
                                           corners: <number>, …;¹
                            @round
                                           corners: <number>, …;
                            @bevel
                                           corners: <number>, …;

¹negative numbers or 0

The default object type of the corners property of @rectangle is round but the default value of the corners property of @rectangle is @straight. In short if you use @ on corners it's @round.

shape: @rectangle;
//is equivalent to
shape: @rectangle { corners: @straight; };

shape: @rectangle { corners: @{ } };
//is equivalent to
shape: @rectangle { corners: @round { } };
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant