@nil-/doc 0.2.20 → 0.2.21
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +8 -0
- package/components/Layout.svelte +1 -6
- package/components/block/Block.svelte +0 -6
- package/components/block/Template.svelte +19 -11
- package/components/block/Template.svelte.d.ts +1 -0
- package/components/block/controls/Range.svelte +2 -2
- package/components/block/controls/misc/Styler.svelte +11 -3
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
package/components/Layout.svelte
CHANGED
|
@@ -12,6 +12,7 @@
|
|
|
12
12
|
padding: 5px;
|
|
13
13
|
display: flex;
|
|
14
14
|
flex-direction: column;
|
|
15
|
+
box-sizing: border-box;
|
|
15
16
|
}
|
|
16
17
|
|
|
17
18
|
/* reset block */
|
|
@@ -27,12 +28,6 @@
|
|
|
27
28
|
font-family: "Fira Code", "Courier New", Courier, monospace;
|
|
28
29
|
}
|
|
29
30
|
|
|
30
|
-
.reset :global(*),
|
|
31
|
-
.reset :global(*::before),
|
|
32
|
-
.reset :global(*::after) {
|
|
33
|
-
box-sizing: inherit;
|
|
34
|
-
}
|
|
35
|
-
|
|
36
31
|
/* scrollable */
|
|
37
32
|
.scrollable {
|
|
38
33
|
overflow: scroll;
|
|
@@ -1,20 +1,24 @@
|
|
|
1
1
|
<style>
|
|
2
2
|
.template {
|
|
3
|
-
display:
|
|
4
|
-
|
|
5
|
-
font-family: "Fira Code", "Courier New", Courier, monospace;
|
|
6
|
-
gap: 20px;
|
|
3
|
+
display: grid;
|
|
4
|
+
gap: 5px;
|
|
7
5
|
padding-bottom: 10px;
|
|
8
6
|
padding-top: 10px;
|
|
9
7
|
}
|
|
10
8
|
|
|
11
|
-
.
|
|
12
|
-
|
|
13
|
-
|
|
9
|
+
.template:not(.column) {
|
|
10
|
+
grid-auto-rows: 1fr;
|
|
11
|
+
grid-auto-columns: auto;
|
|
12
|
+
grid-auto-flow: row;
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
.template.columns {
|
|
16
|
+
grid-auto-rows: auto;
|
|
17
|
+
grid-auto-columns: 1fr;
|
|
18
|
+
grid-auto-flow: column;
|
|
14
19
|
}
|
|
15
20
|
|
|
16
21
|
.content {
|
|
17
|
-
padding: 3px;
|
|
18
22
|
min-height: 100px;
|
|
19
23
|
border-radius: 5px 5px 5px 5px;
|
|
20
24
|
border: rgb(100, 96, 96) solid 1px;
|
|
@@ -22,13 +26,16 @@
|
|
|
22
26
|
}
|
|
23
27
|
|
|
24
28
|
.misc {
|
|
25
|
-
margin-top: 2px;
|
|
26
29
|
outline: rgb(100, 96, 96) solid 1px;
|
|
27
30
|
border-bottom-left-radius: 5px;
|
|
28
31
|
border-bottom-right-radius: 5px;
|
|
29
32
|
user-select: none;
|
|
30
33
|
}
|
|
31
34
|
|
|
35
|
+
.template > div > div {
|
|
36
|
+
margin: 3px;
|
|
37
|
+
}
|
|
38
|
+
|
|
32
39
|
/* scrollable */
|
|
33
40
|
.scrollable {
|
|
34
41
|
overflow: scroll;
|
|
@@ -55,6 +62,7 @@ const controlsState = getControlsState();
|
|
|
55
62
|
const defaultsStore = getDefaults();
|
|
56
63
|
export let defaults = undefined;
|
|
57
64
|
export let noreset = false;
|
|
65
|
+
export let columns = false;
|
|
58
66
|
function reset() {
|
|
59
67
|
$params = [];
|
|
60
68
|
$defaultsStore = defaults;
|
|
@@ -76,10 +84,10 @@ let key = false;
|
|
|
76
84
|
beforeUpdate(() => (key = !key));
|
|
77
85
|
const resolveArgs = (resolve);
|
|
78
86
|
</script>
|
|
79
|
-
<div class="template">
|
|
87
|
+
<div class="template" class:columns>
|
|
80
88
|
{#each $params as param (param.id)}
|
|
81
89
|
<div
|
|
82
|
-
class="
|
|
90
|
+
class="scrollable"
|
|
83
91
|
on:click|stopPropagation={() => ($current = param.id)}
|
|
84
92
|
on:mouseenter={() => (hovered = param.id)}
|
|
85
93
|
on:mouseleave={() => (hovered = null)}
|
|
@@ -1,15 +1,22 @@
|
|
|
1
1
|
<style>
|
|
2
2
|
div {
|
|
3
3
|
width: 100%;
|
|
4
|
+
min-width: 500px;
|
|
5
|
+
overflow: hidden;
|
|
4
6
|
display: grid;
|
|
5
7
|
grid-auto-rows: 30px;
|
|
8
|
+
box-sizing: border-box;
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
div :global(*) {
|
|
12
|
+
box-sizing: inherit;
|
|
6
13
|
}
|
|
7
14
|
|
|
8
15
|
div > :global(div) {
|
|
9
16
|
width: 100%;
|
|
10
17
|
display: grid;
|
|
11
18
|
padding: 2px 0px;
|
|
12
|
-
grid-template-columns: 1fr 200px
|
|
19
|
+
grid-template-columns: minmax(250px, 1fr) 200px 40px;
|
|
13
20
|
background-color: hsl(205, 50%, 5%);
|
|
14
21
|
}
|
|
15
22
|
|
|
@@ -17,8 +24,9 @@
|
|
|
17
24
|
background-color: hsl(205, 15%, 15%);
|
|
18
25
|
}
|
|
19
26
|
|
|
20
|
-
div > :global(div:hover)
|
|
21
|
-
|
|
27
|
+
div > :global(div:hover .tooltip),
|
|
28
|
+
div > :global(div:nth-child(n + 2):hover) {
|
|
29
|
+
background-color: hsl(203, 100%, 15%);
|
|
22
30
|
}
|
|
23
31
|
|
|
24
32
|
div > :global(div > div) {
|