Skip to content

Commit 7638749

Browse files
author
Daniel Dunn
committed
Round feathered, minor fixes
1 parent 5efcaed commit 7638749

File tree

3 files changed

+44
-21
lines changed

3 files changed

+44
-21
lines changed

Diff for: README.md

+8
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,10 @@ Make a link look like it's a button.
5151

5252
## Utilities
5353

54+
### .round-feathered
55+
56+
Make an image smoothly fade out around the edges.
57+
5458
### .paper
5559
This object should have it's own background, it is like a popup you're going to put over something else.
5660

@@ -93,6 +97,10 @@ display: flex.
9397
### .padding
9498
The element will have a reasonable theme dependent amount of padding.
9599

100+
### .padding-bottom
101+
Add padding just to bottom. Useful for fixing scrollbar showing up
102+
when not needed.
103+
96104
### .margin
97105
The element will have a reasonable theme dependent amount of margin.
98106

Diff for: css/barrel.css

+30-17
Original file line numberDiff line numberDiff line change
@@ -269,6 +269,7 @@ header {
269269
header>*:only-child,
270270
header>*:only-child>:only-child {
271271
width: 100%;
272+
flex-grow: 1;
272273
box-sizing: border-box;
273274
margin: 0px;
274275
}
@@ -515,6 +516,7 @@ table tr:first-child td {
515516

516517
.decorative-image {
517518
display: none;
519+
background-size: contain;
518520
}
519521

520522

@@ -527,8 +529,6 @@ table tr:first-child td {
527529
box-sizing: border-box;
528530
overflow-x: auto;
529531
flex-basis: fit-content;
530-
flex-grow: 0.1;
531-
532532
border-color: var(--border-color);
533533
}
534534

@@ -539,7 +539,6 @@ table tr:first-child td {
539539
border-width: var(--border-width);
540540
margin-top: 0.8em;
541541
margin-bottom: 0.2em;
542-
min-width: min-content;
543542
box-sizing: border-box;
544543
max-width: 100vw;
545544
overflow: auto;
@@ -548,7 +547,6 @@ table tr:first-child td {
548547
text-align: left;
549548
flex-grow: 1;
550549
flex-basis: min-content;
551-
resize: both;
552550
}
553551

554552

@@ -579,18 +577,27 @@ table tr:first-child td {
579577
display: flex;
580578
flex-wrap: wrap;
581579
flex-direction: column;
582-
gap: var(--gap);
583580
}
584581

585582
.flex-col>* {
586583
box-sizing: border-box;
587584
flex: 1 1 auto;
588585
flex-basis: fit-content;
586+
margin-block-end: var(--gap);
587+
}
588+
589+
.flex-col>*:last-child {
590+
margin-block-end: 0px;
591+
}
592+
593+
.flex-col>*:nth-last-child(2) {
594+
margin-block-end: 0px;
589595
}
590596

591597
.flex-col footer,
592598
.flex-col header {
593599
flex-grow: 0;
600+
margin-block-end: 0px;
594601
}
595602

596603
.flex-row {
@@ -604,8 +611,6 @@ table tr:first-child td {
604611

605612
.flex-row>* {
606613
box-sizing: border-box;
607-
flex-grow: 1;
608-
flex-shrink: 1;
609614
flex-basis: fit-content;
610615
margin: 0px;
611616
}
@@ -725,13 +730,15 @@ table tr:first-child td {
725730

726731
.nogaps>.col-12 {
727732
width: 100%;
733+
flex-grow: 1;
728734
}
729735

730-
/*Sizes that are relative to approximately the width of a phone screem*/
736+
/*Sizes that are relative to approximately the width of a phone screen.
737+
A little smaller in flex to allow for expansion or fitting lots on a row*/
731738
.w-sm-full {
732739
width: 480px;
733740
max-width: calc(min(480px, 96vw));
734-
flex-basis: 480px;
741+
flex-basis: 320px;
735742
flex-shrink: 1;
736743
}
737744

@@ -924,6 +931,11 @@ table tr:first-child td {
924931

925932
/*Simple utilities */
926933

934+
.round-feathered {
935+
mask-image: radial-gradient(circle, rgba(0, 0, 0, 1) 50%, rgba(0, 0, 0, 0.1) 67%, rgba(0, 0, 0, 0) 71%);
936+
-webkit-mask-image: radial-gradient(circle, rgba(0, 0, 0, 1) 50%, rgba(0, 0, 0, 0.1) 67%, rgba(0, 0, 0, 0) 71%);
937+
}
938+
927939
.paper {
928940
background: var(--box-bg);
929941
}
@@ -955,9 +967,10 @@ iframe.h-center {
955967
gap: 0px;
956968
}
957969

958-
.nogaps>* {
970+
.nogaps>*:not(.specificity_hack) {
959971
margin: 0px;
960972
box-sizing: border-box;
973+
margin-block-end: 0px;
961974
}
962975

963976
.rounded {
@@ -1494,7 +1507,6 @@ header:not(.undecorated)>.tool-bar:only-child :is(a, a.button, select, p, h1, h2
14941507
gap: var(--padding);
14951508
border-top: var(--tool-bar-element-border);
14961509
border-bottom: var(--tool-bar-element-border);
1497-
align-items: center;
14981510
}
14991511

15001512
.tool-bar select {
@@ -1555,9 +1567,8 @@ input[type=range] {
15551567
--concave-item-box-shadow: none;
15561568
}
15571569

1558-
1559-
input[type=range]::-webkit-slider-runnable-track {
1560-
background: var(--control-bg);
1570+
input[type="range"]::-webkit-slider-runnable-track {
1571+
background-color: color-mix(in srgb, var(--control-bg) 70%, var(--control-fg));
15611572
border: var(--thin-border);
15621573
border-radius: 250px;
15631574
height: calc(var(--control-height) / 3);
@@ -1567,14 +1578,15 @@ input[type=range]::-webkit-slider-thumb {
15671578
margin-top: -7.8px;
15681579
width: calc(var(--control-height) / 1.6);
15691580
height: calc(var(--control-height) / 1.2);
1570-
background: var(--control-fg);
1581+
background-color: var(--highlight-color);
15711582
border: var(--thin-border);
1583+
border-width: 2px;
15721584
border-radius: 100px;
15731585
-webkit-appearance: none;
15741586
}
15751587

15761588
input[type=range]::-moz-range-track {
1577-
background: var(--control-bg);
1589+
background-color: color-mix(in srgvb, var(--control-bg) 70%, var(--control-fg));
15781590
border: var(--thin-border);
15791591
border-radius: 250px;
15801592
height: calc(var(--control-height) / 3);
@@ -1583,8 +1595,9 @@ input[type=range]::-moz-range-track {
15831595
input[type=range]::-moz-range-thumb {
15841596
width: calc(var(--control-height) / 1.6);
15851597
height: calc(var(--control-height) / 1.2);
1586-
background: var(--control-fg);
1598+
background-color: color-mix(in srgb, var(--accent-color) 50%, var(--control-bg));
15871599
border: var(--thin-border);
1600+
border-width: 2px;
15881601
border-radius: 100px;
15891602
}
15901603

Diff for: index.html

+6-4
Original file line numberDiff line numberDiff line change
@@ -187,14 +187,16 @@ <h4>Here's a form with no classes</h4>
187187

188188

189189
<h4>Meters</h4>
190-
<p>Styled</p>
191-
<p class="styled">
190+
<p>
191+
<input type="range" class="w-full">
192+
</p>
193+
<p>
192194
<meter class="w-full" min="0" max="100" low="25" high="75" optimum="100" value="10"></meter>
193195
</p>
194-
<p class="styled">
196+
<p>
195197
<meter class="w-full" min="0" max="100" low="25" high="75" optimum="100" value="50"></meter>
196198
</p>
197-
<p class="styled">
199+
<p>
198200
<meter class="w-full" min="0" max="100" low="25" high="75" optimum="100" value="80"></meter>
199201
</p>
200202
</section>

0 commit comments

Comments
 (0)