Pen Settings

HTML

CSS

CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URLs added here will be added as <link>s in order, and before the CSS in the editor. You can use the CSS from another Pen by using its URL and the proper URL extension.

+ add another resource

JavaScript

Babel includes JSX processing.

Add External Scripts/Pens

Any URL's added here will be added as <script>s in order, and run before the JavaScript in the editor. You can use the URL of any other Pen and it will include the JavaScript from that Pen.

+ add another resource

Packages

Add Packages

Search for and use JavaScript packages from npm here. By selecting a package, an import statement will be added to the top of the JavaScript editor for this package.

Behavior

Save Automatically?

If active, Pens will autosave every 30 seconds after being saved once.

Auto-Updating Preview

If enabled, the preview panel updates automatically as you code. If disabled, use the "Run" button to update.

Format on Save

If enabled, your code will be formatted when you actively save your Pen. Note: your code becomes un-folded during formatting.

Editor Settings

Code Indentation

Want to change your Syntax Highlighting theme, Fonts and more?

Visit your global Editor Settings.

HTML

              
                <!--
Go to line 69 to change the pattern.
Click to generate new quilt thing
-->

<style>
    :root {
        --c1: #283D4C;
        --c2: #3D7A84;
        --c3: #CF984E;
        --c4: #B46B56;
        --rule: (--bg: @pick(var(--c1), var(--c2), var(--c3), var(--c4));
                background: linear-gradient(@rand(360deg),
                    @var(--bg) 0 50%,
                    #0000 51%);
            );
        --pattern-1: (--fg : @pick(var(--c1), var(--c2), var(--c3), var(--c4));
                --bg: @pick(var(--c1), var(--c2), var(--c3), var(--c4));
                background-image: linear-gradient(135deg, @var(--fg) 25%, transparent 25%), linear-gradient(225deg, @var(--fg) 25%, transparent 25%), linear-gradient(45deg, @var(--fg) 25%, transparent 25%), linear-gradient(315deg, @var(--fg) 25%, @var(--bg) 25%);
                background-position: 10px 0, 10px 0, 0 0, 0 0;
                background-size: 20px 20px;
                background-repeat: repeat;
                transform: rotate(@rand(360)deg);
            );
        --pattern-2: (--fg : @pick(var(--c1), var(--c2), var(--c3), var(--c4));
                --bg: @pick(var(--c1), var(--c2), var(--c3), var(--c4));
                background-image: linear-gradient(0deg, @var(--bg) 50%, @var(--fg) 50%);
                background-size: 22px 22px;
                transform: rotate(@rand(360)deg);
            );
        --pattern-3: (--fg : @pick(var(--c1), var(--c2), var(--c3), var(--c4));
                --bg: @pick(var(--c1), var(--c2), var(--c3), var(--c4));
                background-image: repeating-linear-gradient(45deg, @var(--fg) 25%, transparent 25%, transparent 75%, @var(--fg) 75%, @var(--fg)), repeating-linear-gradient(45deg, @var(--fg) 25%, @var(--bg) 25%, @var(--bg) 75%, @var(--fg) 75%, @var(--fg));
                background-position: 0 0, 10px 10px;
                background-size: 20px 20px;
                transform: rotate(@rand(360)deg);
            );
        --pattern-4: (--fg : @pick(var(--c1), var(--c2), var(--c3), var(--c4));
                --bg: @pick(var(--c1), var(--c2), var(--c3), var(--c4));
                background-image: linear-gradient(45deg, @var(--fg) 50%, @var(--bg) 50%);
                background-size: 14px 14px;
                transform: rotate(@rand(360)deg);
            );
    }
</style>

<css-doodle click-to-update>
    <style>
        :doodle {
            @grid: 10;
            --cell-scale: 1;
        }

        :doodle(:hover) {
            --cell-scale: 0.9;
        }

        overflow: hidden;
        @size : calc(95vmin / @Y);
        background: @pick(var(--c1), var(--c2), var(--c3), var(--c4));
        transform: scale(var(--cell-scale));
        transition: transform 450ms ease @rand(0.4)s;

        ::after {
            content: '';
            background: @pick(var(--c1), var(--c2), var(--c3), var(--c4));
            @size: 100%;
            /* Change to pattern-1,2,3,4 for a different pattern*/
            @use: var(--pattern-1);
            clip-path: @shape(points: @pick(3, 4, 5);
                    scale: @rand(0.8, 1.5);
                    move: @r(-1, 1), @r(-1, 1);
                );
        }

        ;
    </style>
</css-doodle>
              
            
!

CSS

              
                html,
body {
    height: 100%;
    background: #cfccc9;
    margin: 0;
    display: grid;
    place-items: center;
}

              
            
!

JS

              
                /*

CSS Quilt made with css-doodle!
Made for @sableRaph: https://www.twitch.tv/sableraph

Thanks Koma Tebe for telling me about this amazing CSS framework!

Click to generate a new quilt.
Go to line 70 in HTML to change pattern.

So this isn't much, but I only started playing around
with this framework a few hours ago. I might have done
a few stupid stuff, so I'll probably revise this sometime
in the future.

Also, fun fact, the traditional quilts in Bengal
is known as Kantha. Check it out!

- Rishi

*/

              
            
!
999px

Console