@functionalcms/svelte-components 5.4.1 → 5.4.4
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/css/functional.css +45 -45
- package/dist/components/Icon.svelte +16 -16
- package/dist/components/content/Markdown.svelte +10 -10
- package/dist/components/form/AntiBot.svelte +12 -12
- package/dist/components/form/Dropzone.svelte +180 -180
- package/dist/components/form/SmartForm.svelte +269 -271
- package/dist/components/form/SmartForm.svelte.d.ts +1 -1
- package/dist/components/form/form.d.ts +1 -1
- package/dist/components/form/form.js +2 -2
- package/dist/components/head/Font.svelte +20 -20
- package/dist/components/head/Meta.svelte +28 -28
- package/dist/components/head/Tracker.svelte +18 -18
- package/dist/components/integrations/EasyTools.svelte +30 -30
- package/dist/components/layouts/DefaultLayout.svelte +117 -117
- package/dist/components/layouts/MenuLayout.svelte +79 -79
- package/dist/components/layouts/SimpleLayout.svelte +19 -19
- package/dist/components/presentation/FlexBox.svelte +73 -73
- package/dist/components/presentation/ImageCompare.svelte +180 -180
- package/dist/components/presentation/Logo.svelte +37 -37
- package/dist/components/presentation/StyleBox.svelte +17 -17
- package/dist/components/presentation/Well.svelte +17 -17
- package/package.json +75 -75
|
@@ -1,73 +1,73 @@
|
|
|
1
|
-
<script lang="ts">
|
|
2
|
-
import type { Snippet } from 'svelte';
|
|
3
|
-
|
|
4
|
-
interface Props {
|
|
5
|
-
children: Snippet;
|
|
6
|
-
width?: string;
|
|
7
|
-
height?: string;
|
|
8
|
-
direction: 'row' | 'column' | 'row-reverse' | 'column-reverse';
|
|
9
|
-
justify?:
|
|
10
|
-
| 'start'
|
|
11
|
-
| 'end'
|
|
12
|
-
| 'end-safe'
|
|
13
|
-
| 'center'
|
|
14
|
-
| 'center-safe'
|
|
15
|
-
| 'between'
|
|
16
|
-
| 'around'
|
|
17
|
-
| 'evenly'
|
|
18
|
-
| 'stretch'
|
|
19
|
-
| 'baseline'
|
|
20
|
-
| 'normal';
|
|
21
|
-
align?:
|
|
22
|
-
| 'start'
|
|
23
|
-
| 'end'
|
|
24
|
-
| 'end-safe'
|
|
25
|
-
| 'center'
|
|
26
|
-
| 'center-safe'
|
|
27
|
-
| 'baseline'
|
|
28
|
-
| 'baseline-last'
|
|
29
|
-
| 'stretch';
|
|
30
|
-
wrap: 'wrap' | 'nowrap' | 'wrap-reverse';
|
|
31
|
-
grow?: string;
|
|
32
|
-
shrink?: string;
|
|
33
|
-
gap?: string;
|
|
34
|
-
margin?: string;
|
|
35
|
-
padding?: string;
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
let {
|
|
39
|
-
children,
|
|
40
|
-
width = 'auto',
|
|
41
|
-
height = 'auto',
|
|
42
|
-
direction = 'row',
|
|
43
|
-
justify = 'start',
|
|
44
|
-
align = 'stretch',
|
|
45
|
-
gap = '0',
|
|
46
|
-
wrap = 'nowrap',
|
|
47
|
-
grow = undefined,
|
|
48
|
-
shrink = undefined,
|
|
49
|
-
margin = undefined,
|
|
50
|
-
padding = undefined,
|
|
51
|
-
}: Partial<Props> = $props();
|
|
52
|
-
|
|
53
|
-
const cssClass = $derived(
|
|
54
|
-
[
|
|
55
|
-
`box`,
|
|
56
|
-
`flex flex-${direction}`,
|
|
57
|
-
`justify-${justify}`,
|
|
58
|
-
`items-${align}`,
|
|
59
|
-
`gap-${gap}`,
|
|
60
|
-
`flex-${wrap}`,
|
|
61
|
-
`w-${width}`,
|
|
62
|
-
`h-${height}`,
|
|
63
|
-
grow ? `flex-grow-${grow}` : '',
|
|
64
|
-
shrink ? `flex-shrink-${shrink}` : '',
|
|
65
|
-
margin ? `m-${margin}` : '',
|
|
66
|
-
padding ? `p-${padding}` : '',
|
|
67
|
-
].join(' ')
|
|
68
|
-
);
|
|
69
|
-
</script>
|
|
70
|
-
|
|
71
|
-
<div class={cssClass}>
|
|
72
|
-
{@render children?.()}
|
|
73
|
-
</div>
|
|
1
|
+
<script lang="ts">
|
|
2
|
+
import type { Snippet } from 'svelte';
|
|
3
|
+
|
|
4
|
+
interface Props {
|
|
5
|
+
children: Snippet;
|
|
6
|
+
width?: string;
|
|
7
|
+
height?: string;
|
|
8
|
+
direction: 'row' | 'column' | 'row-reverse' | 'column-reverse';
|
|
9
|
+
justify?:
|
|
10
|
+
| 'start'
|
|
11
|
+
| 'end'
|
|
12
|
+
| 'end-safe'
|
|
13
|
+
| 'center'
|
|
14
|
+
| 'center-safe'
|
|
15
|
+
| 'between'
|
|
16
|
+
| 'around'
|
|
17
|
+
| 'evenly'
|
|
18
|
+
| 'stretch'
|
|
19
|
+
| 'baseline'
|
|
20
|
+
| 'normal';
|
|
21
|
+
align?:
|
|
22
|
+
| 'start'
|
|
23
|
+
| 'end'
|
|
24
|
+
| 'end-safe'
|
|
25
|
+
| 'center'
|
|
26
|
+
| 'center-safe'
|
|
27
|
+
| 'baseline'
|
|
28
|
+
| 'baseline-last'
|
|
29
|
+
| 'stretch';
|
|
30
|
+
wrap: 'wrap' | 'nowrap' | 'wrap-reverse';
|
|
31
|
+
grow?: string;
|
|
32
|
+
shrink?: string;
|
|
33
|
+
gap?: string;
|
|
34
|
+
margin?: string;
|
|
35
|
+
padding?: string;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
let {
|
|
39
|
+
children,
|
|
40
|
+
width = 'auto',
|
|
41
|
+
height = 'auto',
|
|
42
|
+
direction = 'row',
|
|
43
|
+
justify = 'start',
|
|
44
|
+
align = 'stretch',
|
|
45
|
+
gap = '0',
|
|
46
|
+
wrap = 'nowrap',
|
|
47
|
+
grow = undefined,
|
|
48
|
+
shrink = undefined,
|
|
49
|
+
margin = undefined,
|
|
50
|
+
padding = undefined,
|
|
51
|
+
}: Partial<Props> = $props();
|
|
52
|
+
|
|
53
|
+
const cssClass = $derived(
|
|
54
|
+
[
|
|
55
|
+
`box`,
|
|
56
|
+
`flex flex-${direction}`,
|
|
57
|
+
`justify-${justify}`,
|
|
58
|
+
`items-${align}`,
|
|
59
|
+
`gap-${gap}`,
|
|
60
|
+
`flex-${wrap}`,
|
|
61
|
+
`w-${width}`,
|
|
62
|
+
`h-${height}`,
|
|
63
|
+
grow ? `flex-grow-${grow}` : '',
|
|
64
|
+
shrink ? `flex-shrink-${shrink}` : '',
|
|
65
|
+
margin ? `m-${margin}` : '',
|
|
66
|
+
padding ? `p-${padding}` : '',
|
|
67
|
+
].join(' ')
|
|
68
|
+
);
|
|
69
|
+
</script>
|
|
70
|
+
|
|
71
|
+
<div class={cssClass}>
|
|
72
|
+
{@render children?.()}
|
|
73
|
+
</div>
|
|
@@ -1,180 +1,180 @@
|
|
|
1
|
-
<script lang="ts">
|
|
2
|
-
import { type Snippet } from "svelte";
|
|
3
|
-
|
|
4
|
-
interface Props {
|
|
5
|
-
imageLeftSrc: string;
|
|
6
|
-
imageLeftAlt: string;
|
|
7
|
-
imageRightSrc: string;
|
|
8
|
-
imageRightAlt: string;
|
|
9
|
-
slidertLabel: Snippet;
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
let {
|
|
13
|
-
imageLeftSrc = "",
|
|
14
|
-
imageLeftAlt = "",
|
|
15
|
-
imageRightSrc = "",
|
|
16
|
-
imageRightAlt = "",
|
|
17
|
-
slidertLabel,
|
|
18
|
-
}: Partial<Props> = $props();
|
|
19
|
-
|
|
20
|
-
let sliderPosition: number = $state(50);
|
|
21
|
-
let animationFrame: number | null = $state(null);
|
|
22
|
-
|
|
23
|
-
function handleInput(e: Event) {
|
|
24
|
-
if (animationFrame) cancelAnimationFrame(animationFrame);
|
|
25
|
-
|
|
26
|
-
animationFrame = requestAnimationFrame(() => {
|
|
27
|
-
sliderPosition = (e.target as HTMLInputElement).valueAsNumber;
|
|
28
|
-
});
|
|
29
|
-
}
|
|
30
|
-
|
|
31
|
-
function handleClick(e: Event) {
|
|
32
|
-
(e.target as HTMLInputElement).focus();
|
|
33
|
-
}
|
|
34
|
-
</script>
|
|
35
|
-
|
|
36
|
-
<div
|
|
37
|
-
class="svelte-compare-image-container"
|
|
38
|
-
style="--slider-position: {sliderPosition}%;"
|
|
39
|
-
>
|
|
40
|
-
<img src={imageLeftSrc} alt={imageLeftAlt} class="left-img" />
|
|
41
|
-
<img src={imageRightSrc} alt={imageRightAlt} class="right-img" />
|
|
42
|
-
|
|
43
|
-
<label>
|
|
44
|
-
<input
|
|
45
|
-
type="range"
|
|
46
|
-
min="0"
|
|
47
|
-
max="100"
|
|
48
|
-
value={sliderPosition}
|
|
49
|
-
oninput={handleInput}
|
|
50
|
-
onchange={handleInput}
|
|
51
|
-
onclick={handleClick}
|
|
52
|
-
/>
|
|
53
|
-
</label>
|
|
54
|
-
</div>
|
|
55
|
-
|
|
56
|
-
<style>
|
|
57
|
-
.svelte-compare-image-container {
|
|
58
|
-
box-sizing: border-box;
|
|
59
|
-
position: relative;
|
|
60
|
-
overflow: hidden;
|
|
61
|
-
}
|
|
62
|
-
|
|
63
|
-
.svelte-compare-image-container:focus-within {
|
|
64
|
-
outline: auto 4px rgba(59, 153, 252, 0.7);
|
|
65
|
-
outline: auto 4px Highlight;
|
|
66
|
-
outline: auto 4px -moz-mac-focusring;
|
|
67
|
-
outline: auto 4px -webkit-focus-ring-color;
|
|
68
|
-
}
|
|
69
|
-
|
|
70
|
-
img {
|
|
71
|
-
display: block;
|
|
72
|
-
height: auto;
|
|
73
|
-
width: 100%;
|
|
74
|
-
margin: 0;
|
|
75
|
-
}
|
|
76
|
-
|
|
77
|
-
.left-img {
|
|
78
|
-
clip-path: polygon(
|
|
79
|
-
0 0,
|
|
80
|
-
var(--slider-position) 0,
|
|
81
|
-
var(--slider-position) 100%,
|
|
82
|
-
0 100%
|
|
83
|
-
);
|
|
84
|
-
}
|
|
85
|
-
|
|
86
|
-
.right-img {
|
|
87
|
-
position: absolute;
|
|
88
|
-
top: 0;
|
|
89
|
-
clip-path: polygon(
|
|
90
|
-
var(--slider-position) 0,
|
|
91
|
-
100% 0,
|
|
92
|
-
100% 100%,
|
|
93
|
-
var(--slider-position) 100%
|
|
94
|
-
);
|
|
95
|
-
}
|
|
96
|
-
|
|
97
|
-
label {
|
|
98
|
-
position: absolute;
|
|
99
|
-
display: flex;
|
|
100
|
-
align-items: stretch;
|
|
101
|
-
top: 0;
|
|
102
|
-
left: 0;
|
|
103
|
-
bottom: 0;
|
|
104
|
-
right: 0;
|
|
105
|
-
background: transparent;
|
|
106
|
-
}
|
|
107
|
-
|
|
108
|
-
label::before {
|
|
109
|
-
content: "";
|
|
110
|
-
position: absolute;
|
|
111
|
-
top: 0;
|
|
112
|
-
bottom: 0;
|
|
113
|
-
left: calc(var(--slider-position) - var(--slider-width, 0.125rem) / 2);
|
|
114
|
-
width: var(--slider-width, 0.125rem);
|
|
115
|
-
background: var(--slider-color, #ffffff);
|
|
116
|
-
pointer-events: none;
|
|
117
|
-
}
|
|
118
|
-
|
|
119
|
-
input[type="range"] {
|
|
120
|
-
position: relative;
|
|
121
|
-
cursor: col-resize;
|
|
122
|
-
margin: 0 calc(var(--handle-size, 2.5rem) / -2);
|
|
123
|
-
width: calc(100% + var(--handle-size, 2.5rem));
|
|
124
|
-
padding: 0;
|
|
125
|
-
border-radius: 0;
|
|
126
|
-
appearance: none;
|
|
127
|
-
-webkit-appearance: none;
|
|
128
|
-
background: none;
|
|
129
|
-
border: none;
|
|
130
|
-
}
|
|
131
|
-
|
|
132
|
-
input[type="range"]::-moz-range-thumb {
|
|
133
|
-
display: flex;
|
|
134
|
-
justify-content: center;
|
|
135
|
-
align-items: center;
|
|
136
|
-
background-color: var(--handle-background-color, rgba(0, 0, 0, 0.6));
|
|
137
|
-
background-image: var(
|
|
138
|
-
--handle-background-image,
|
|
139
|
-
url('data:image/svg+xml;utf8,<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M3 12H21M3 12L7 8M3 12L7 16M21 12L17 16M21 12L17 8" stroke="white" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/></svg>')
|
|
140
|
-
);
|
|
141
|
-
background-size: 80%;
|
|
142
|
-
background-position: center center;
|
|
143
|
-
background-repeat: no-repeat;
|
|
144
|
-
border: var(--handle-border-width, 0.125rem) solid
|
|
145
|
-
var(--slider-color, #ffffff);
|
|
146
|
-
border-radius: 100%;
|
|
147
|
-
box-shadow:
|
|
148
|
-
0 3px 1px -2px rgba(0, 0, 0, 0.2),
|
|
149
|
-
0 2px 2px 0 rgba(0, 0, 0, 0.14),
|
|
150
|
-
0 1px 5px 0 rgba(0, 0, 0, 0.12);
|
|
151
|
-
color: var(--slider-color, #ffffff);
|
|
152
|
-
width: var(--handle-size, 2.5rem);
|
|
153
|
-
height: var(--handle-size, 2.5rem);
|
|
154
|
-
}
|
|
155
|
-
|
|
156
|
-
input[type="range"]::-webkit-slider-thumb {
|
|
157
|
-
-webkit-appearance: none;
|
|
158
|
-
display: flex;
|
|
159
|
-
justify-content: center;
|
|
160
|
-
align-items: center;
|
|
161
|
-
background-color: var(--handle-background-color, rgba(0, 0, 0, 0.6));
|
|
162
|
-
background-image: var(
|
|
163
|
-
--handle-background-image,
|
|
164
|
-
url('data:image/svg+xml;utf8,<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M3 12H21M3 12L7 8M3 12L7 16M21 12L17 16M21 12L17 8" stroke="white" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/></svg>')
|
|
165
|
-
);
|
|
166
|
-
background-size: 80%;
|
|
167
|
-
background-position: center center;
|
|
168
|
-
background-repeat: no-repeat;
|
|
169
|
-
border: var(--handle-border-width, 0.125rem) solid
|
|
170
|
-
var(--slider-color, #ffffff);
|
|
171
|
-
border-radius: 100%;
|
|
172
|
-
box-shadow:
|
|
173
|
-
0 3px 1px -2px rgba(0, 0, 0, 0.2),
|
|
174
|
-
0 2px 2px 0 rgba(0, 0, 0, 0.14),
|
|
175
|
-
0 1px 5px 0 rgba(0, 0, 0, 0.12);
|
|
176
|
-
color: var(--slider-color, #ffffff);
|
|
177
|
-
width: var(--handle-size, 2.5rem);
|
|
178
|
-
height: var(--handle-size, 2.5rem);
|
|
179
|
-
}
|
|
180
|
-
</style>
|
|
1
|
+
<script lang="ts">
|
|
2
|
+
import { type Snippet } from "svelte";
|
|
3
|
+
|
|
4
|
+
interface Props {
|
|
5
|
+
imageLeftSrc: string;
|
|
6
|
+
imageLeftAlt: string;
|
|
7
|
+
imageRightSrc: string;
|
|
8
|
+
imageRightAlt: string;
|
|
9
|
+
slidertLabel: Snippet;
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
let {
|
|
13
|
+
imageLeftSrc = "",
|
|
14
|
+
imageLeftAlt = "",
|
|
15
|
+
imageRightSrc = "",
|
|
16
|
+
imageRightAlt = "",
|
|
17
|
+
slidertLabel,
|
|
18
|
+
}: Partial<Props> = $props();
|
|
19
|
+
|
|
20
|
+
let sliderPosition: number = $state(50);
|
|
21
|
+
let animationFrame: number | null = $state(null);
|
|
22
|
+
|
|
23
|
+
function handleInput(e: Event) {
|
|
24
|
+
if (animationFrame) cancelAnimationFrame(animationFrame);
|
|
25
|
+
|
|
26
|
+
animationFrame = requestAnimationFrame(() => {
|
|
27
|
+
sliderPosition = (e.target as HTMLInputElement).valueAsNumber;
|
|
28
|
+
});
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
function handleClick(e: Event) {
|
|
32
|
+
(e.target as HTMLInputElement).focus();
|
|
33
|
+
}
|
|
34
|
+
</script>
|
|
35
|
+
|
|
36
|
+
<div
|
|
37
|
+
class="svelte-compare-image-container"
|
|
38
|
+
style="--slider-position: {sliderPosition}%;"
|
|
39
|
+
>
|
|
40
|
+
<img src={imageLeftSrc} alt={imageLeftAlt} class="left-img" />
|
|
41
|
+
<img src={imageRightSrc} alt={imageRightAlt} class="right-img" />
|
|
42
|
+
|
|
43
|
+
<label>
|
|
44
|
+
<input
|
|
45
|
+
type="range"
|
|
46
|
+
min="0"
|
|
47
|
+
max="100"
|
|
48
|
+
value={sliderPosition}
|
|
49
|
+
oninput={handleInput}
|
|
50
|
+
onchange={handleInput}
|
|
51
|
+
onclick={handleClick}
|
|
52
|
+
/>
|
|
53
|
+
</label>
|
|
54
|
+
</div>
|
|
55
|
+
|
|
56
|
+
<style>
|
|
57
|
+
.svelte-compare-image-container {
|
|
58
|
+
box-sizing: border-box;
|
|
59
|
+
position: relative;
|
|
60
|
+
overflow: hidden;
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
.svelte-compare-image-container:focus-within {
|
|
64
|
+
outline: auto 4px rgba(59, 153, 252, 0.7);
|
|
65
|
+
outline: auto 4px Highlight;
|
|
66
|
+
outline: auto 4px -moz-mac-focusring;
|
|
67
|
+
outline: auto 4px -webkit-focus-ring-color;
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
img {
|
|
71
|
+
display: block;
|
|
72
|
+
height: auto;
|
|
73
|
+
width: 100%;
|
|
74
|
+
margin: 0;
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
.left-img {
|
|
78
|
+
clip-path: polygon(
|
|
79
|
+
0 0,
|
|
80
|
+
var(--slider-position) 0,
|
|
81
|
+
var(--slider-position) 100%,
|
|
82
|
+
0 100%
|
|
83
|
+
);
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
.right-img {
|
|
87
|
+
position: absolute;
|
|
88
|
+
top: 0;
|
|
89
|
+
clip-path: polygon(
|
|
90
|
+
var(--slider-position) 0,
|
|
91
|
+
100% 0,
|
|
92
|
+
100% 100%,
|
|
93
|
+
var(--slider-position) 100%
|
|
94
|
+
);
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
label {
|
|
98
|
+
position: absolute;
|
|
99
|
+
display: flex;
|
|
100
|
+
align-items: stretch;
|
|
101
|
+
top: 0;
|
|
102
|
+
left: 0;
|
|
103
|
+
bottom: 0;
|
|
104
|
+
right: 0;
|
|
105
|
+
background: transparent;
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
label::before {
|
|
109
|
+
content: "";
|
|
110
|
+
position: absolute;
|
|
111
|
+
top: 0;
|
|
112
|
+
bottom: 0;
|
|
113
|
+
left: calc(var(--slider-position) - var(--slider-width, 0.125rem) / 2);
|
|
114
|
+
width: var(--slider-width, 0.125rem);
|
|
115
|
+
background: var(--slider-color, #ffffff);
|
|
116
|
+
pointer-events: none;
|
|
117
|
+
}
|
|
118
|
+
|
|
119
|
+
input[type="range"] {
|
|
120
|
+
position: relative;
|
|
121
|
+
cursor: col-resize;
|
|
122
|
+
margin: 0 calc(var(--handle-size, 2.5rem) / -2);
|
|
123
|
+
width: calc(100% + var(--handle-size, 2.5rem));
|
|
124
|
+
padding: 0;
|
|
125
|
+
border-radius: 0;
|
|
126
|
+
appearance: none;
|
|
127
|
+
-webkit-appearance: none;
|
|
128
|
+
background: none;
|
|
129
|
+
border: none;
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
input[type="range"]::-moz-range-thumb {
|
|
133
|
+
display: flex;
|
|
134
|
+
justify-content: center;
|
|
135
|
+
align-items: center;
|
|
136
|
+
background-color: var(--handle-background-color, rgba(0, 0, 0, 0.6));
|
|
137
|
+
background-image: var(
|
|
138
|
+
--handle-background-image,
|
|
139
|
+
url('data:image/svg+xml;utf8,<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M3 12H21M3 12L7 8M3 12L7 16M21 12L17 16M21 12L17 8" stroke="white" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/></svg>')
|
|
140
|
+
);
|
|
141
|
+
background-size: 80%;
|
|
142
|
+
background-position: center center;
|
|
143
|
+
background-repeat: no-repeat;
|
|
144
|
+
border: var(--handle-border-width, 0.125rem) solid
|
|
145
|
+
var(--slider-color, #ffffff);
|
|
146
|
+
border-radius: 100%;
|
|
147
|
+
box-shadow:
|
|
148
|
+
0 3px 1px -2px rgba(0, 0, 0, 0.2),
|
|
149
|
+
0 2px 2px 0 rgba(0, 0, 0, 0.14),
|
|
150
|
+
0 1px 5px 0 rgba(0, 0, 0, 0.12);
|
|
151
|
+
color: var(--slider-color, #ffffff);
|
|
152
|
+
width: var(--handle-size, 2.5rem);
|
|
153
|
+
height: var(--handle-size, 2.5rem);
|
|
154
|
+
}
|
|
155
|
+
|
|
156
|
+
input[type="range"]::-webkit-slider-thumb {
|
|
157
|
+
-webkit-appearance: none;
|
|
158
|
+
display: flex;
|
|
159
|
+
justify-content: center;
|
|
160
|
+
align-items: center;
|
|
161
|
+
background-color: var(--handle-background-color, rgba(0, 0, 0, 0.6));
|
|
162
|
+
background-image: var(
|
|
163
|
+
--handle-background-image,
|
|
164
|
+
url('data:image/svg+xml;utf8,<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M3 12H21M3 12L7 8M3 12L7 16M21 12L17 16M21 12L17 8" stroke="white" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/></svg>')
|
|
165
|
+
);
|
|
166
|
+
background-size: 80%;
|
|
167
|
+
background-position: center center;
|
|
168
|
+
background-repeat: no-repeat;
|
|
169
|
+
border: var(--handle-border-width, 0.125rem) solid
|
|
170
|
+
var(--slider-color, #ffffff);
|
|
171
|
+
border-radius: 100%;
|
|
172
|
+
box-shadow:
|
|
173
|
+
0 3px 1px -2px rgba(0, 0, 0, 0.2),
|
|
174
|
+
0 2px 2px 0 rgba(0, 0, 0, 0.14),
|
|
175
|
+
0 1px 5px 0 rgba(0, 0, 0, 0.12);
|
|
176
|
+
color: var(--slider-color, #ffffff);
|
|
177
|
+
width: var(--handle-size, 2.5rem);
|
|
178
|
+
height: var(--handle-size, 2.5rem);
|
|
179
|
+
}
|
|
180
|
+
</style>
|
|
@@ -1,37 +1,37 @@
|
|
|
1
|
-
<script lang="ts">
|
|
2
|
-
interface Props {
|
|
3
|
-
companyName: string;
|
|
4
|
-
logoUrl: string;
|
|
5
|
-
css: string;
|
|
6
|
-
}
|
|
7
|
-
|
|
8
|
-
let {
|
|
9
|
-
companyName,
|
|
10
|
-
logoUrl,
|
|
11
|
-
css = 'logo'
|
|
12
|
-
}: Partial<Props> = $props();
|
|
13
|
-
|
|
14
|
-
</script>
|
|
15
|
-
|
|
16
|
-
<a href="/" class={css}>
|
|
17
|
-
<img src={logoUrl} alt={companyName} loading="lazy" />
|
|
18
|
-
</a>
|
|
19
|
-
|
|
20
|
-
<style>
|
|
21
|
-
a {
|
|
22
|
-
display: var(--logo-display, 'inline-block');
|
|
23
|
-
margin: var(--mobile-logo-margin);
|
|
24
|
-
padding: var(--mobile-logo-padding);
|
|
25
|
-
}
|
|
26
|
-
a img {
|
|
27
|
-
width: 100%;
|
|
28
|
-
width: var(--logo-width, 200px);
|
|
29
|
-
}
|
|
30
|
-
|
|
31
|
-
@media (min-width: 960px) {
|
|
32
|
-
a img {
|
|
33
|
-
margin: var(--logo-margin);
|
|
34
|
-
padding: var(--logo-padding);
|
|
35
|
-
}
|
|
36
|
-
}
|
|
37
|
-
</style>
|
|
1
|
+
<script lang="ts">
|
|
2
|
+
interface Props {
|
|
3
|
+
companyName: string;
|
|
4
|
+
logoUrl: string;
|
|
5
|
+
css: string;
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
let {
|
|
9
|
+
companyName,
|
|
10
|
+
logoUrl,
|
|
11
|
+
css = 'logo'
|
|
12
|
+
}: Partial<Props> = $props();
|
|
13
|
+
|
|
14
|
+
</script>
|
|
15
|
+
|
|
16
|
+
<a href="/" class={css}>
|
|
17
|
+
<img src={logoUrl} alt={companyName} loading="lazy" />
|
|
18
|
+
</a>
|
|
19
|
+
|
|
20
|
+
<style>
|
|
21
|
+
a {
|
|
22
|
+
display: var(--logo-display, 'inline-block');
|
|
23
|
+
margin: var(--mobile-logo-margin);
|
|
24
|
+
padding: var(--mobile-logo-padding);
|
|
25
|
+
}
|
|
26
|
+
a img {
|
|
27
|
+
width: 100%;
|
|
28
|
+
width: var(--logo-width, 200px);
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
@media (min-width: 960px) {
|
|
32
|
+
a img {
|
|
33
|
+
margin: var(--logo-margin);
|
|
34
|
+
padding: var(--logo-padding);
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
</style>
|
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
<script lang="ts">
|
|
2
|
-
import type { Snippet } from 'svelte';
|
|
3
|
-
|
|
4
|
-
interface Props {
|
|
5
|
-
children: Snippet;
|
|
6
|
-
class: string;
|
|
7
|
-
}
|
|
8
|
-
|
|
9
|
-
let {
|
|
10
|
-
children,
|
|
11
|
-
class: css = '',
|
|
12
|
-
}: Partial<Props> = $props();
|
|
13
|
-
</script>
|
|
14
|
-
|
|
15
|
-
<div class={css}>
|
|
16
|
-
{@render children?.()}
|
|
17
|
-
</div>
|
|
1
|
+
<script lang="ts">
|
|
2
|
+
import type { Snippet } from 'svelte';
|
|
3
|
+
|
|
4
|
+
interface Props {
|
|
5
|
+
children: Snippet;
|
|
6
|
+
class: string;
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
let {
|
|
10
|
+
children,
|
|
11
|
+
class: css = '',
|
|
12
|
+
}: Partial<Props> = $props();
|
|
13
|
+
</script>
|
|
14
|
+
|
|
15
|
+
<div class={css}>
|
|
16
|
+
{@render children?.()}
|
|
17
|
+
</div>
|
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
<script lang="ts">
|
|
2
|
-
import type { Snippet } from 'svelte';
|
|
3
|
-
|
|
4
|
-
interface Props {
|
|
5
|
-
children: Snippet;
|
|
6
|
-
class: string;
|
|
7
|
-
}
|
|
8
|
-
|
|
9
|
-
let {
|
|
10
|
-
children,
|
|
11
|
-
class: css = '',
|
|
12
|
-
}: Partial<Props> = $props();
|
|
13
|
-
</script>
|
|
14
|
-
|
|
15
|
-
<div class="well m-auto p-1 {css}">
|
|
16
|
-
{@render children?.()}
|
|
17
|
-
</div>
|
|
1
|
+
<script lang="ts">
|
|
2
|
+
import type { Snippet } from 'svelte';
|
|
3
|
+
|
|
4
|
+
interface Props {
|
|
5
|
+
children: Snippet;
|
|
6
|
+
class: string;
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
let {
|
|
10
|
+
children,
|
|
11
|
+
class: css = '',
|
|
12
|
+
}: Partial<Props> = $props();
|
|
13
|
+
</script>
|
|
14
|
+
|
|
15
|
+
<div class="well m-auto p-1 {css}">
|
|
16
|
+
{@render children?.()}
|
|
17
|
+
</div>
|