@hyvor/design 0.0.67 → 1.0.3
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/dist/components/ActionList/ActionList.svelte +21 -13
- package/dist/components/ActionList/ActionList.svelte.d.ts +8 -20
- package/dist/components/ActionList/ActionListGroup.svelte +40 -35
- package/dist/components/ActionList/ActionListGroup.svelte.d.ts +8 -20
- package/dist/components/ActionList/ActionListItem.svelte +129 -107
- package/dist/components/ActionList/ActionListItem.svelte.d.ts +27 -25
- package/dist/components/ActionList/Selected.svelte +27 -24
- package/dist/components/ActionList/Selected.svelte.d.ts +6 -17
- package/dist/components/Avatar/Avatar.svelte +22 -19
- package/dist/components/Avatar/Avatar.svelte.d.ts +7 -18
- package/dist/components/Avatar/AvatarStack.svelte +29 -27
- package/dist/components/Avatar/AvatarStack.svelte.d.ts +6 -18
- package/dist/components/Base/Base.svelte +16 -8
- package/dist/components/Base/Base.svelte.d.ts +6 -18
- package/dist/components/Box/Box.svelte +16 -9
- package/dist/components/Box/Box.svelte.d.ts +7 -19
- package/dist/components/Button/Button.svelte +65 -47
- package/dist/components/Button/Button.svelte.d.ts +16 -39
- package/dist/components/Button/ButtonGroup.svelte +14 -6
- package/dist/components/Button/ButtonGroup.svelte.d.ts +5 -27
- package/dist/components/Callout/Callout.svelte +110 -87
- package/dist/components/Callout/Callout.svelte.d.ts +11 -22
- package/dist/components/Checkbox/Checkbox.svelte +156 -144
- package/dist/components/Checkbox/Checkbox.svelte.d.ts +11 -34
- package/dist/components/CodeBlock/CodeBlock.svelte +45 -32
- package/dist/components/CodeBlock/CodeBlock.svelte.d.ts +6 -17
- package/dist/components/CodeBlock/getCode.js +8 -6
- package/dist/components/CodeBlock/hljs.scss +189 -191
- package/dist/components/CodeBlock/prism.scss +370 -7
- package/dist/components/ColorPicker/ColorPicker.svelte +75 -56
- package/dist/components/ColorPicker/ColorPicker.svelte.d.ts +25 -19
- package/dist/components/Dark/DarkProvider.svelte +16 -14
- package/dist/components/Dark/DarkProvider.svelte.d.ts +16 -12
- package/dist/components/Dark/DarkToggle.svelte +15 -16
- package/dist/components/Dark/DarkToggle.svelte.d.ts +16 -12
- package/dist/components/Divider/Divider.svelte +23 -13
- package/dist/components/Divider/Divider.svelte.d.ts +9 -20
- package/dist/components/Dropdown/Dropdown.svelte +58 -114
- package/dist/components/Dropdown/Dropdown.svelte.d.ts +13 -24
- package/dist/components/Dropdown/DropdownContent.svelte +152 -0
- package/dist/components/Dropdown/DropdownContent.svelte.d.ts +12 -0
- package/dist/components/FormControl/Caption.svelte +18 -11
- package/dist/components/FormControl/Caption.svelte.d.ts +7 -19
- package/dist/components/FormControl/FormControl.svelte +28 -19
- package/dist/components/FormControl/FormControl.svelte.d.ts +6 -27
- package/dist/components/FormControl/InputGroup.svelte +22 -15
- package/dist/components/FormControl/InputGroup.svelte.d.ts +7 -19
- package/dist/components/FormControl/Label.svelte +15 -6
- package/dist/components/FormControl/Label.svelte.d.ts +6 -27
- package/dist/components/FormControl/Validation.svelte +30 -19
- package/dist/components/FormControl/Validation.svelte.d.ts +9 -21
- package/dist/components/HyvorBar/BarProducts.svelte +71 -0
- package/dist/components/HyvorBar/BarProducts.svelte.d.ts +32 -0
- package/dist/components/HyvorBar/BarSupport.svelte +183 -0
- package/dist/components/HyvorBar/BarSupport.svelte.d.ts +8 -0
- package/dist/components/HyvorBar/BarUpdates.svelte +68 -0
- package/dist/components/HyvorBar/BarUpdates.svelte.d.ts +7 -0
- package/dist/components/HyvorBar/BarUpdatesList.svelte +159 -0
- package/dist/components/HyvorBar/BarUpdatesList.svelte.d.ts +7 -0
- package/dist/components/HyvorBar/BarUser.svelte +72 -0
- package/dist/components/HyvorBar/BarUser.svelte.d.ts +5 -0
- package/dist/components/HyvorBar/BarUserPreview.svelte +43 -0
- package/dist/components/HyvorBar/BarUserPreview.svelte.d.ts +18 -0
- package/dist/components/HyvorBar/HyvorBar.svelte +183 -0
- package/dist/components/HyvorBar/HyvorBar.svelte.d.ts +8 -0
- package/dist/components/HyvorBar/bar.d.ts +33 -0
- package/dist/components/HyvorBar/bar.js +74 -0
- package/dist/components/HyvorBar/img/G2.svelte +9 -0
- package/dist/components/HyvorBar/img/G2.svelte.d.ts +26 -0
- package/dist/components/HyvorBar/img/Trustpilot.svelte +11 -0
- package/dist/components/HyvorBar/img/Trustpilot.svelte.d.ts +26 -0
- package/dist/components/IconButton/IconButton.svelte +49 -32
- package/dist/components/IconButton/IconButton.svelte.d.ts +10 -33
- package/dist/components/IconMessage/IconMessage.svelte +157 -51
- package/dist/components/IconMessage/IconMessage.svelte.d.ts +19 -27
- package/dist/components/Internationalization/InternationalizationProvider.svelte +15 -8
- package/dist/components/Internationalization/InternationalizationProvider.svelte.d.ts +7 -19
- package/dist/components/Internationalization/LanguageToggle.svelte +80 -57
- package/dist/components/Internationalization/LanguageToggle.svelte.d.ts +11 -22
- package/dist/components/Internationalization/T.svelte +158 -114
- package/dist/components/Internationalization/T.svelte.d.ts +17 -15
- package/dist/components/Internationalization/i18n.d.ts +3 -5
- package/dist/components/Internationalization/i18n.js +13 -11
- package/dist/components/Internationalization/t.d.ts +2 -3
- package/dist/components/Internationalization/t.js +4 -4
- package/dist/components/Internationalization/types.d.ts +2 -1
- package/dist/components/Link/Link.svelte +68 -61
- package/dist/components/Link/Link.svelte.d.ts +11 -34
- package/dist/components/Loader/LoadButton.svelte +39 -38
- package/dist/components/Loader/LoadButton.svelte.d.ts +29 -42
- package/dist/components/Loader/Loader.svelte +121 -107
- package/dist/components/Loader/Loader.svelte.d.ts +15 -27
- package/dist/components/Modal/ConfirmModalProvider.svelte +41 -51
- package/dist/components/Modal/ConfirmModalProvider.svelte.d.ts +3 -14
- package/dist/components/Modal/Modal.svelte +202 -203
- package/dist/components/Modal/Modal.svelte.d.ts +31 -29
- package/dist/components/Modal/ModalFooter.svelte +36 -31
- package/dist/components/Modal/ModalFooter.svelte.d.ts +22 -18
- package/dist/components/Modal/confirm.d.ts +2 -2
- package/dist/components/Modal/confirm.js +4 -4
- package/dist/components/Modal/modal-types.d.ts +4 -4
- package/dist/components/NavLink/NavLink.svelte +94 -89
- package/dist/components/NavLink/NavLink.svelte.d.ts +11 -33
- package/dist/components/Radio/Radio.svelte +46 -35
- package/dist/components/Radio/Radio.svelte.d.ts +10 -33
- package/dist/components/Slider/Slider.svelte +129 -120
- package/dist/components/Slider/Slider.svelte.d.ts +24 -20
- package/dist/components/SplitControl/SplitControl.svelte +43 -48
- package/dist/components/SplitControl/SplitControl.svelte.d.ts +11 -24
- package/dist/components/Switch/Switch.svelte +77 -67
- package/dist/components/Switch/Switch.svelte.d.ts +8 -31
- package/dist/components/TabNav/TabNav.svelte +33 -23
- package/dist/components/TabNav/TabNav.svelte.d.ts +7 -19
- package/dist/components/TabNav/TabNavItem.svelte +65 -51
- package/dist/components/TabNav/TabNavItem.svelte.d.ts +10 -24
- package/dist/components/Table/Table.svelte +17 -7
- package/dist/components/Table/Table.svelte.d.ts +7 -19
- package/dist/components/Table/TableRow.svelte +32 -24
- package/dist/components/Table/TableRow.svelte.d.ts +7 -19
- package/dist/components/Tag/Tag.svelte +75 -49
- package/dist/components/Tag/Tag.svelte.d.ts +16 -39
- package/dist/components/Text/Text.svelte +33 -26
- package/dist/components/Text/Text.svelte.d.ts +10 -22
- package/dist/components/TextInput/TextInput.svelte +54 -33
- package/dist/components/TextInput/TextInput.svelte.d.ts +12 -36
- package/dist/components/Textarea/Textarea.svelte +68 -46
- package/dist/components/Textarea/Textarea.svelte.d.ts +13 -37
- package/dist/components/Toast/ToastIcon.svelte +55 -46
- package/dist/components/Toast/ToastIcon.svelte.d.ts +5 -16
- package/dist/components/Toast/ToastMessage.svelte +42 -41
- package/dist/components/Toast/ToastMessage.svelte.d.ts +5 -16
- package/dist/components/Toast/ToastProvider.svelte +22 -20
- package/dist/components/Toast/ToastProvider.svelte.d.ts +16 -12
- package/dist/components/Toast/cleaner.js +5 -5
- package/dist/components/Toast/toast.d.ts +3 -3
- package/dist/components/Toast/toast.js +10 -10
- package/dist/components/Tooltip/Tooltip.svelte +163 -148
- package/dist/components/Tooltip/Tooltip.svelte.d.ts +35 -23
- package/dist/components/directives/clickOutside.js +4 -4
- package/dist/components/directives/debounce.d.ts +1 -0
- package/dist/components/directives/debounce.js +8 -0
- package/dist/components/index.d.ts +1 -0
- package/dist/components/index.js +1 -0
- package/dist/index.css +31 -33
- package/dist/marketing/Container/Container.svelte +15 -9
- package/dist/marketing/Container/Container.svelte.d.ts +6 -18
- package/dist/marketing/Docs/Content/Content.svelte +48 -35
- package/dist/marketing/Docs/Content/Content.svelte.d.ts +5 -16
- package/dist/marketing/Docs/Content/DocsImage.svelte +67 -69
- package/dist/marketing/Docs/Content/DocsImage.svelte.d.ts +9 -20
- package/dist/marketing/Docs/Docs.svelte +28 -25
- package/dist/marketing/Docs/Docs.svelte.d.ts +6 -29
- package/dist/marketing/Docs/Nav/Nav.svelte +96 -70
- package/dist/marketing/Docs/Nav/Nav.svelte.d.ts +5 -16
- package/dist/marketing/Docs/Nav/NavCategory.svelte +39 -29
- package/dist/marketing/Docs/Nav/NavCategory.svelte.d.ts +8 -20
- package/dist/marketing/Docs/Nav/NavItem.svelte +30 -26
- package/dist/marketing/Docs/Nav/NavItem.svelte.d.ts +6 -18
- package/dist/marketing/Docs/Sidebar/Sidebar.svelte +22 -25
- package/dist/marketing/Docs/Sidebar/Sidebar.svelte.d.ts +22 -19
- package/dist/marketing/Docs/Toc.svelte +64 -56
- package/dist/marketing/Docs/Toc.svelte.d.ts +3 -14
- package/dist/marketing/Document/Document.svelte +15 -8
- package/dist/marketing/Document/Document.svelte.d.ts +7 -19
- package/dist/marketing/Document/DocumentTitle.svelte +65 -54
- package/dist/marketing/Document/DocumentTitle.svelte.d.ts +9 -20
- package/dist/marketing/Footer/Footer.svelte +154 -145
- package/dist/marketing/Footer/Footer.svelte.d.ts +8 -20
- package/dist/marketing/Footer/FooterLinkList.svelte +31 -27
- package/dist/marketing/Footer/FooterLinkList.svelte.d.ts +6 -18
- package/dist/marketing/Header/Header.svelte +47 -37
- package/dist/marketing/Header/Header.svelte.d.ts +10 -22
- package/dist/marketing/Logo/LogoBlogs.svelte +46 -0
- package/dist/marketing/Logo/LogoBlogs.svelte.d.ts +5 -0
- package/dist/marketing/Logo/LogoCore.svelte +46 -0
- package/dist/marketing/Logo/LogoCore.svelte.d.ts +5 -0
- package/dist/marketing/Logo/LogoFortguard.svelte +54 -0
- package/dist/marketing/Logo/LogoFortguard.svelte.d.ts +5 -0
- package/dist/marketing/Logo/LogoTalk.svelte +32 -0
- package/dist/marketing/Logo/LogoTalk.svelte.d.ts +5 -0
- package/dist/stores/dark.d.ts +0 -1
- package/dist/stores/dark.js +8 -8
- package/dist/variables.scss +41 -48
- package/package.json +59 -58
|
@@ -1,12 +1,375 @@
|
|
|
1
|
-
|
|
1
|
+
/* PrismJS 1.26.0
|
|
2
2
|
https://prismjs.com/download.html#themes=prism&languages=markup+css+clike+javascript+json+markup-templating+php+twig+yaml&plugins=line-highlight+line-numbers */
|
|
3
|
-
code[class*=language-
|
|
4
|
-
pre[
|
|
5
|
-
|
|
3
|
+
code[class*='language-'],
|
|
4
|
+
pre[class*='language-'] {
|
|
5
|
+
color: #000;
|
|
6
|
+
background: 0 0;
|
|
7
|
+
text-shadow: 0 1px #fff;
|
|
8
|
+
font-family: Consolas, Monaco, 'Andale Mono', 'Ubuntu Mono', monospace;
|
|
9
|
+
text-align: left;
|
|
10
|
+
white-space: pre;
|
|
11
|
+
word-spacing: normal;
|
|
12
|
+
word-break: normal;
|
|
13
|
+
word-wrap: normal;
|
|
14
|
+
line-height: 1.5;
|
|
15
|
+
-moz-tab-size: 4;
|
|
16
|
+
-o-tab-size: 4;
|
|
17
|
+
tab-size: 4;
|
|
18
|
+
-webkit-hyphens: none;
|
|
19
|
+
-moz-hyphens: none;
|
|
20
|
+
-ms-hyphens: none;
|
|
21
|
+
hyphens: none;
|
|
22
|
+
}
|
|
23
|
+
code[class*='language-'] ::-moz-selection,
|
|
24
|
+
code[class*='language-']::-moz-selection,
|
|
25
|
+
pre[class*='language-'] ::-moz-selection,
|
|
26
|
+
pre[class*='language-']::-moz-selection {
|
|
27
|
+
text-shadow: none;
|
|
28
|
+
background: #b3d4fc;
|
|
29
|
+
}
|
|
30
|
+
code[class*='language-'] ::selection,
|
|
31
|
+
code[class*='language-']::selection,
|
|
32
|
+
pre[class*='language-'] ::selection,
|
|
33
|
+
pre[class*='language-']::selection {
|
|
34
|
+
text-shadow: none;
|
|
35
|
+
background: #b3d4fc;
|
|
36
|
+
}
|
|
37
|
+
@media print {
|
|
38
|
+
code[class*='language-'],
|
|
39
|
+
pre[class*='language-'] {
|
|
40
|
+
text-shadow: none;
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
pre[class*='language-'] {
|
|
44
|
+
padding: 1em;
|
|
45
|
+
margin: 0.5em 0;
|
|
46
|
+
overflow: auto;
|
|
47
|
+
}
|
|
48
|
+
:not(pre) > code[class*='language-'],
|
|
49
|
+
pre[class*='language-'] {
|
|
50
|
+
background: #f5f2f0;
|
|
51
|
+
}
|
|
52
|
+
:not(pre) > code[class*='language-'] {
|
|
53
|
+
padding: 0.1em;
|
|
54
|
+
border-radius: 0.3em;
|
|
55
|
+
white-space: normal;
|
|
56
|
+
}
|
|
57
|
+
.token.cdata,
|
|
58
|
+
.token.comment,
|
|
59
|
+
.token.doctype,
|
|
60
|
+
.token.prolog {
|
|
61
|
+
color: #708090;
|
|
62
|
+
}
|
|
63
|
+
.token.punctuation {
|
|
64
|
+
color: #999;
|
|
65
|
+
}
|
|
66
|
+
.token.namespace {
|
|
67
|
+
opacity: 0.7;
|
|
68
|
+
}
|
|
69
|
+
.token.boolean,
|
|
70
|
+
.token.constant,
|
|
71
|
+
.token.deleted,
|
|
72
|
+
.token.number,
|
|
73
|
+
.token.property,
|
|
74
|
+
.token.symbol,
|
|
75
|
+
.token.tag {
|
|
76
|
+
color: #905;
|
|
77
|
+
}
|
|
78
|
+
.token.attr-name,
|
|
79
|
+
.token.builtin,
|
|
80
|
+
.token.char,
|
|
81
|
+
.token.inserted,
|
|
82
|
+
.token.selector,
|
|
83
|
+
.token.string {
|
|
84
|
+
color: #690;
|
|
85
|
+
}
|
|
86
|
+
.language-css .token.string,
|
|
87
|
+
.style .token.string,
|
|
88
|
+
.token.entity,
|
|
89
|
+
.token.operator,
|
|
90
|
+
.token.url {
|
|
91
|
+
color: #9a6e3a;
|
|
92
|
+
background: hsla(0, 0%, 100%, 0.5);
|
|
93
|
+
}
|
|
94
|
+
.token.atrule,
|
|
95
|
+
.token.attr-value,
|
|
96
|
+
.token.keyword {
|
|
97
|
+
color: #07a;
|
|
98
|
+
}
|
|
99
|
+
.token.class-name,
|
|
100
|
+
.token.function {
|
|
101
|
+
color: #dd4a68;
|
|
102
|
+
}
|
|
103
|
+
.token.important,
|
|
104
|
+
.token.regex,
|
|
105
|
+
.token.variable {
|
|
106
|
+
color: #e90;
|
|
107
|
+
}
|
|
108
|
+
.token.bold,
|
|
109
|
+
.token.important {
|
|
110
|
+
font-weight: 700;
|
|
111
|
+
}
|
|
112
|
+
.token.italic {
|
|
113
|
+
font-style: italic;
|
|
114
|
+
}
|
|
115
|
+
.token.entity {
|
|
116
|
+
cursor: help;
|
|
117
|
+
}
|
|
118
|
+
pre[data-line] {
|
|
119
|
+
position: relative;
|
|
120
|
+
padding: 1em 0 1em 3em;
|
|
121
|
+
}
|
|
122
|
+
.line-highlight {
|
|
123
|
+
position: absolute;
|
|
124
|
+
left: 0;
|
|
125
|
+
right: 0;
|
|
126
|
+
padding: inherit 0;
|
|
127
|
+
margin-top: 1em;
|
|
128
|
+
background: hsla(24, 20%, 50%, 0.08);
|
|
129
|
+
background: linear-gradient(to right, hsla(24, 20%, 50%, 0.1) 70%, hsla(24, 20%, 50%, 0));
|
|
130
|
+
pointer-events: none;
|
|
131
|
+
line-height: inherit;
|
|
132
|
+
white-space: pre;
|
|
133
|
+
}
|
|
134
|
+
@media print {
|
|
135
|
+
.line-highlight {
|
|
136
|
+
-webkit-print-color-adjust: exact;
|
|
137
|
+
color-adjust: exact;
|
|
138
|
+
}
|
|
139
|
+
}
|
|
140
|
+
.line-highlight:before,
|
|
141
|
+
.line-highlight[data-end]:after {
|
|
142
|
+
content: attr(data-start);
|
|
143
|
+
position: absolute;
|
|
144
|
+
top: 0.4em;
|
|
145
|
+
left: 0.6em;
|
|
146
|
+
min-width: 1em;
|
|
147
|
+
padding: 0 0.5em;
|
|
148
|
+
background-color: hsla(24, 20%, 50%, 0.4);
|
|
149
|
+
color: #f4f1ef;
|
|
150
|
+
font: bold 65%/1.5 sans-serif;
|
|
151
|
+
text-align: center;
|
|
152
|
+
vertical-align: 0.3em;
|
|
153
|
+
border-radius: 999px;
|
|
154
|
+
text-shadow: none;
|
|
155
|
+
box-shadow: 0 1px #fff;
|
|
156
|
+
}
|
|
157
|
+
.line-highlight[data-end]:after {
|
|
158
|
+
content: attr(data-end);
|
|
159
|
+
top: auto;
|
|
160
|
+
bottom: 0.4em;
|
|
161
|
+
}
|
|
162
|
+
.line-numbers .line-highlight:after,
|
|
163
|
+
.line-numbers .line-highlight:before {
|
|
164
|
+
content: none;
|
|
165
|
+
}
|
|
166
|
+
pre[id].linkable-line-numbers span.line-numbers-rows {
|
|
167
|
+
pointer-events: all;
|
|
168
|
+
}
|
|
169
|
+
pre[id].linkable-line-numbers span.line-numbers-rows > span:before {
|
|
170
|
+
cursor: pointer;
|
|
171
|
+
}
|
|
172
|
+
pre[id].linkable-line-numbers span.line-numbers-rows > span:hover:before {
|
|
173
|
+
background-color: rgba(128, 128, 128, 0.2);
|
|
174
|
+
}
|
|
175
|
+
pre[class*='language-'].line-numbers {
|
|
176
|
+
position: relative;
|
|
177
|
+
padding-left: 3.8em;
|
|
178
|
+
counter-reset: linenumber;
|
|
179
|
+
}
|
|
180
|
+
pre[class*='language-'].line-numbers > code {
|
|
181
|
+
position: relative;
|
|
182
|
+
white-space: inherit;
|
|
183
|
+
}
|
|
184
|
+
.line-numbers .line-numbers-rows {
|
|
185
|
+
position: absolute;
|
|
186
|
+
pointer-events: none;
|
|
187
|
+
top: 0;
|
|
188
|
+
font-size: 100%;
|
|
189
|
+
left: -3.8em;
|
|
190
|
+
width: 3em;
|
|
191
|
+
letter-spacing: -1px;
|
|
192
|
+
border-right: 1px solid #999;
|
|
193
|
+
-webkit-user-select: none;
|
|
194
|
+
-moz-user-select: none;
|
|
195
|
+
-ms-user-select: none;
|
|
196
|
+
user-select: none;
|
|
197
|
+
}
|
|
198
|
+
.line-numbers-rows > span {
|
|
199
|
+
display: block;
|
|
200
|
+
counter-increment: linenumber;
|
|
201
|
+
}
|
|
202
|
+
.line-numbers-rows > span:before {
|
|
203
|
+
content: counter(linenumber);
|
|
204
|
+
color: #999;
|
|
205
|
+
display: block;
|
|
206
|
+
padding-right: 0.8em;
|
|
207
|
+
text-align: right;
|
|
208
|
+
}
|
|
6
209
|
|
|
7
210
|
/* to make jsx look the same as HTML */
|
|
8
|
-
pre[class=
|
|
211
|
+
pre[class='language-tsx'] .token.class-name {
|
|
212
|
+
color: #905;
|
|
213
|
+
}
|
|
9
214
|
|
|
10
215
|
:root.dark {
|
|
11
|
-
|
|
12
|
-
|
|
216
|
+
code[class*='language-'],
|
|
217
|
+
pre[class*='language-'] {
|
|
218
|
+
color: #d4d4d4;
|
|
219
|
+
text-shadow: none;
|
|
220
|
+
font-family: Menlo, Monaco, Consolas, 'Andale Mono', 'Ubuntu Mono', 'Courier New', monospace;
|
|
221
|
+
direction: ltr;
|
|
222
|
+
text-align: left;
|
|
223
|
+
white-space: pre;
|
|
224
|
+
word-spacing: normal;
|
|
225
|
+
word-break: normal;
|
|
226
|
+
line-height: 1.5;
|
|
227
|
+
-moz-tab-size: 4;
|
|
228
|
+
-o-tab-size: 4;
|
|
229
|
+
tab-size: 4;
|
|
230
|
+
-webkit-hyphens: none;
|
|
231
|
+
-moz-hyphens: none;
|
|
232
|
+
-ms-hyphens: none;
|
|
233
|
+
hyphens: none;
|
|
234
|
+
}
|
|
235
|
+
code[class*='language-'] ::selection,
|
|
236
|
+
code[class*='language-']::selection,
|
|
237
|
+
pre[class*='language-'] ::selection,
|
|
238
|
+
pre[class*='language-']::selection {
|
|
239
|
+
text-shadow: none;
|
|
240
|
+
background: #264f78;
|
|
241
|
+
}
|
|
242
|
+
@media print {
|
|
243
|
+
code[class*='language-'],
|
|
244
|
+
pre[class*='language-'] {
|
|
245
|
+
text-shadow: none;
|
|
246
|
+
}
|
|
247
|
+
}
|
|
248
|
+
pre[class*='language-'] {
|
|
249
|
+
padding: 1em;
|
|
250
|
+
margin: 0.5em 0;
|
|
251
|
+
overflow: auto;
|
|
252
|
+
background: #262626;
|
|
253
|
+
}
|
|
254
|
+
:not(pre) > code[class*='language-'] {
|
|
255
|
+
padding: 0.1em 0.3em;
|
|
256
|
+
border-radius: 0.3em;
|
|
257
|
+
color: #db4c69;
|
|
258
|
+
background: #262626;
|
|
259
|
+
}
|
|
260
|
+
.namespace {
|
|
261
|
+
opacity: 0.7;
|
|
262
|
+
}
|
|
263
|
+
.token.boolean,
|
|
264
|
+
.token.doctype .token.doctype-tag,
|
|
265
|
+
.token.entity,
|
|
266
|
+
.token.important,
|
|
267
|
+
.token.keyword,
|
|
268
|
+
.token.operator.arrow,
|
|
269
|
+
.token.punctuation.interpolation-punctuation,
|
|
270
|
+
.token.tag {
|
|
271
|
+
color: #569cd6;
|
|
272
|
+
}
|
|
273
|
+
.token.atrule .token.url,
|
|
274
|
+
.token.attr-name,
|
|
275
|
+
.token.console,
|
|
276
|
+
.token.constant,
|
|
277
|
+
.token.doctype .token.name,
|
|
278
|
+
.token.exports .token.maybe-class-name,
|
|
279
|
+
.token.imports .token.maybe-class-name,
|
|
280
|
+
.token.interpolation,
|
|
281
|
+
.token.parameter,
|
|
282
|
+
.token.property,
|
|
283
|
+
.token.variable,
|
|
284
|
+
code[class*='language-javascript'],
|
|
285
|
+
code[class*='language-jsx'],
|
|
286
|
+
code[class*='language-tsx'],
|
|
287
|
+
code[class*='language-typescript'],
|
|
288
|
+
pre[class*='language-javascript'],
|
|
289
|
+
pre[class*='language-jsx'],
|
|
290
|
+
pre[class*='language-tsx'],
|
|
291
|
+
pre[class*='language-typescript'] {
|
|
292
|
+
color: #9cdcfe;
|
|
293
|
+
}
|
|
294
|
+
.token.comment,
|
|
295
|
+
.token.prolog {
|
|
296
|
+
color: #6a9955;
|
|
297
|
+
}
|
|
298
|
+
.language-html .language-css .token.punctuation,
|
|
299
|
+
.language-html .language-javascript .token.punctuation,
|
|
300
|
+
.token.atrule .token.url .token.punctuation,
|
|
301
|
+
.token.attr-value .token.punctuation.attr-equals,
|
|
302
|
+
.token.entity,
|
|
303
|
+
.token.operator,
|
|
304
|
+
.token.punctuation,
|
|
305
|
+
code[class*='language-html'],
|
|
306
|
+
pre[class*='language-html'] {
|
|
307
|
+
color: #d4d4d4;
|
|
308
|
+
}
|
|
309
|
+
.token.boolean,
|
|
310
|
+
.token.constant,
|
|
311
|
+
.token.inserted,
|
|
312
|
+
.token.number,
|
|
313
|
+
.token.property,
|
|
314
|
+
.token.symbol,
|
|
315
|
+
.token.tag,
|
|
316
|
+
.token.unit {
|
|
317
|
+
color: #b5cea8;
|
|
318
|
+
}
|
|
319
|
+
.token.atrule,
|
|
320
|
+
.token.attr-name,
|
|
321
|
+
.token.attr-value,
|
|
322
|
+
.token.attr-value .token.punctuation,
|
|
323
|
+
.token.builtin,
|
|
324
|
+
.token.char,
|
|
325
|
+
.token.deleted,
|
|
326
|
+
.token.selector,
|
|
327
|
+
.token.string,
|
|
328
|
+
code[class*='language-css'],
|
|
329
|
+
pre[class*='language-css'] {
|
|
330
|
+
color: #ce9178;
|
|
331
|
+
}
|
|
332
|
+
.language-css .token.string.url {
|
|
333
|
+
text-decoration: underline;
|
|
334
|
+
}
|
|
335
|
+
.token.atrule .token.rule,
|
|
336
|
+
.token.keyword.control-flow,
|
|
337
|
+
.token.keyword.module {
|
|
338
|
+
color: #c586c0;
|
|
339
|
+
}
|
|
340
|
+
.language-regex .token.anchor,
|
|
341
|
+
.token.atrule .token.url .token.function,
|
|
342
|
+
.token.function,
|
|
343
|
+
.token.function .token.maybe-class-name {
|
|
344
|
+
color: #dcdcaa;
|
|
345
|
+
}
|
|
346
|
+
.token.regex {
|
|
347
|
+
color: #d16969;
|
|
348
|
+
}
|
|
349
|
+
.token.italic {
|
|
350
|
+
font-style: italic;
|
|
351
|
+
}
|
|
352
|
+
.token.class-name,
|
|
353
|
+
.token.maybe-class-name,
|
|
354
|
+
.token.namespace {
|
|
355
|
+
color: #4ec9b0;
|
|
356
|
+
}
|
|
357
|
+
.token.escape,
|
|
358
|
+
.token.selector {
|
|
359
|
+
color: #d7ba7d;
|
|
360
|
+
}
|
|
361
|
+
.language-html .token.punctuation,
|
|
362
|
+
.token.cdata,
|
|
363
|
+
.token.tag .token.punctuation {
|
|
364
|
+
color: grey;
|
|
365
|
+
}
|
|
366
|
+
pre[class*='language-'] > code[class*='language-'] {
|
|
367
|
+
position: relative;
|
|
368
|
+
z-index: 1;
|
|
369
|
+
}
|
|
370
|
+
.line-highlight.line-highlight {
|
|
371
|
+
background: #f7ebc6;
|
|
372
|
+
box-shadow: inset 5px 0 0 #f7d87c;
|
|
373
|
+
z-index: 0;
|
|
374
|
+
}
|
|
375
|
+
}
|
|
@@ -1,64 +1,83 @@
|
|
|
1
|
-
<script
|
|
2
|
-
import
|
|
3
|
-
import {
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
1
|
+
<script lang="ts">
|
|
2
|
+
import ColorPicker from 'svelte-awesome-color-picker';
|
|
3
|
+
import { clickOutside } from '../index.js';
|
|
4
|
+
import { createEventDispatcher } from 'svelte';
|
|
5
|
+
|
|
6
|
+
interface Props {
|
|
7
|
+
color?: string;
|
|
8
|
+
size?: number;
|
|
9
|
+
show?: boolean;
|
|
10
|
+
'aria-label'?: string;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
let {
|
|
14
|
+
color = $bindable('#000000'),
|
|
15
|
+
size = 30,
|
|
16
|
+
show = $bindable(false),
|
|
17
|
+
'aria-label': ariaLabel = ''
|
|
18
|
+
}: Props = $props();
|
|
19
|
+
|
|
20
|
+
const dispatch = createEventDispatcher<{
|
|
21
|
+
input: string;
|
|
22
|
+
change: string;
|
|
23
|
+
}>();
|
|
24
|
+
|
|
25
|
+
function handleInput() {
|
|
26
|
+
dispatch('input', color);
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
function handleClose() {
|
|
30
|
+
dispatch('change', color);
|
|
31
|
+
show = false;
|
|
32
|
+
}
|
|
15
33
|
</script>
|
|
16
34
|
|
|
17
35
|
<span class="color-picker">
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
36
|
+
<button
|
|
37
|
+
style:width="{size}px"
|
|
38
|
+
style:height="{size}px"
|
|
39
|
+
style:background-color={color}
|
|
40
|
+
onclick={() => {
|
|
41
|
+
if (show) {
|
|
42
|
+
handleClose();
|
|
43
|
+
} else {
|
|
44
|
+
show = true;
|
|
45
|
+
}
|
|
46
|
+
}}
|
|
47
|
+
aria-label={ariaLabel}
|
|
48
|
+
></button>
|
|
30
49
|
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
50
|
+
{#if show}
|
|
51
|
+
<div
|
|
52
|
+
class="color-picker-wrap"
|
|
53
|
+
use:clickOutside={{
|
|
54
|
+
callback: () => handleClose()
|
|
55
|
+
}}
|
|
56
|
+
>
|
|
57
|
+
<ColorPicker
|
|
58
|
+
bind:hex={color}
|
|
59
|
+
--input-size={size + 'px'}
|
|
60
|
+
isDialog={false}
|
|
61
|
+
isAlpha={false}
|
|
62
|
+
on:input={handleInput}
|
|
63
|
+
/>
|
|
64
|
+
</div>
|
|
65
|
+
{/if}
|
|
47
66
|
</span>
|
|
48
67
|
|
|
49
68
|
<style>
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
69
|
+
span {
|
|
70
|
+
position: relative;
|
|
71
|
+
}
|
|
72
|
+
button {
|
|
73
|
+
border-radius: 50%;
|
|
74
|
+
border: 1px solid var(--border);
|
|
75
|
+
}
|
|
76
|
+
div {
|
|
77
|
+
position: absolute;
|
|
78
|
+
left: 0;
|
|
79
|
+
top: 100%;
|
|
80
|
+
width: 0;
|
|
81
|
+
z-index: 1000;
|
|
82
|
+
}
|
|
64
83
|
</style>
|
|
@@ -1,21 +1,27 @@
|
|
|
1
|
-
import
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
1
|
+
import ColorPicker from 'svelte-awesome-color-picker';
|
|
2
|
+
interface $$__sveltets_2_IsomorphicComponent<Props extends Record<string, any> = any, Events extends Record<string, any> = any, Slots extends Record<string, any> = any, Exports = {}, Bindings = string> {
|
|
3
|
+
new (options: import('svelte').ComponentConstructorOptions<Props>): import('svelte').SvelteComponent<Props, Events, Slots> & {
|
|
4
|
+
$$bindings?: Bindings;
|
|
5
|
+
} & Exports;
|
|
6
|
+
(internal: unknown, props: Props & {
|
|
7
|
+
$$events?: Events;
|
|
8
|
+
$$slots?: Slots;
|
|
9
|
+
}): Exports & {
|
|
10
|
+
$set?: any;
|
|
11
|
+
$on?: any;
|
|
7
12
|
};
|
|
8
|
-
|
|
9
|
-
input: CustomEvent<string>;
|
|
10
|
-
change: CustomEvent<string>;
|
|
11
|
-
} & {
|
|
12
|
-
[evt: string]: CustomEvent<any>;
|
|
13
|
-
};
|
|
14
|
-
slots: {};
|
|
15
|
-
};
|
|
16
|
-
export type ColorPickerProps = typeof __propDef.props;
|
|
17
|
-
export type ColorPickerEvents = typeof __propDef.events;
|
|
18
|
-
export type ColorPickerSlots = typeof __propDef.slots;
|
|
19
|
-
export default class ColorPicker extends SvelteComponent<ColorPickerProps, ColorPickerEvents, ColorPickerSlots> {
|
|
13
|
+
z_$$bindings?: Bindings;
|
|
20
14
|
}
|
|
21
|
-
|
|
15
|
+
declare const ColorPicker: $$__sveltets_2_IsomorphicComponent<{
|
|
16
|
+
color?: string;
|
|
17
|
+
size?: number;
|
|
18
|
+
show?: boolean;
|
|
19
|
+
'aria-label'?: string;
|
|
20
|
+
}, {
|
|
21
|
+
input: CustomEvent<string>;
|
|
22
|
+
change: CustomEvent<string>;
|
|
23
|
+
} & {
|
|
24
|
+
[evt: string]: CustomEvent<any>;
|
|
25
|
+
}, {}, {}, "color" | "show">;
|
|
26
|
+
type ColorPicker = InstanceType<typeof ColorPicker>;
|
|
27
|
+
export default ColorPicker;
|
|
@@ -1,17 +1,19 @@
|
|
|
1
|
-
<script
|
|
2
|
-
import {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
1
|
+
<script lang="ts">
|
|
2
|
+
import { onMount } from 'svelte';
|
|
3
|
+
import { setInitialState } from '../../stores/dark.js';
|
|
4
|
+
|
|
5
|
+
onMount(() => {
|
|
6
|
+
setInitialState();
|
|
7
|
+
});
|
|
6
8
|
</script>
|
|
7
9
|
|
|
8
10
|
<svelte:head>
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
</svelte:head>
|
|
11
|
+
<script>
|
|
12
|
+
// to prevent white screen on page load
|
|
13
|
+
// until the dark mode is initialized from the store
|
|
14
|
+
const isDarkMode = !!localStorage.getItem('scheme-dark');
|
|
15
|
+
if (isDarkMode) {
|
|
16
|
+
document.documentElement.classList.add('dark');
|
|
17
|
+
}
|
|
18
|
+
</script>
|
|
19
|
+
</svelte:head>
|
|
@@ -1,14 +1,18 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
1
|
+
interface $$__sveltets_2_IsomorphicComponent<Props extends Record<string, any> = any, Events extends Record<string, any> = any, Slots extends Record<string, any> = any, Exports = {}, Bindings = string> {
|
|
2
|
+
new (options: import('svelte').ComponentConstructorOptions<Props>): import('svelte').SvelteComponent<Props, Events, Slots> & {
|
|
3
|
+
$$bindings?: Bindings;
|
|
4
|
+
} & Exports;
|
|
5
|
+
(internal: unknown, props: {
|
|
6
|
+
$$events?: Events;
|
|
7
|
+
$$slots?: Slots;
|
|
8
|
+
}): Exports & {
|
|
9
|
+
$set?: any;
|
|
10
|
+
$on?: any;
|
|
6
11
|
};
|
|
7
|
-
|
|
8
|
-
};
|
|
9
|
-
export type DarkProviderProps = typeof __propDef.props;
|
|
10
|
-
export type DarkProviderEvents = typeof __propDef.events;
|
|
11
|
-
export type DarkProviderSlots = typeof __propDef.slots;
|
|
12
|
-
export default class DarkProvider extends SvelteComponent<DarkProviderProps, DarkProviderEvents, DarkProviderSlots> {
|
|
12
|
+
z_$$bindings?: Bindings;
|
|
13
13
|
}
|
|
14
|
-
|
|
14
|
+
declare const DarkProvider: $$__sveltets_2_IsomorphicComponent<Record<string, never>, {
|
|
15
|
+
[evt: string]: CustomEvent<any>;
|
|
16
|
+
}, {}, {}, string>;
|
|
17
|
+
type DarkProvider = InstanceType<typeof DarkProvider>;
|
|
18
|
+
export default DarkProvider;
|
|
@@ -1,18 +1,17 @@
|
|
|
1
|
-
<script
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
1
|
+
<script lang="ts">
|
|
2
|
+
import { IconMoonStarsFill, IconSunFill } from '@hyvor/icons';
|
|
3
|
+
import IconButton from '../IconButton/IconButton.svelte';
|
|
4
|
+
import { dark } from './../../stores/dark.js';
|
|
5
|
+
|
|
6
|
+
function handleClick() {
|
|
7
|
+
dark.update((value) => !value);
|
|
8
|
+
}
|
|
7
9
|
</script>
|
|
8
10
|
|
|
9
|
-
<IconButton
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
<IconSunFill size={18} />
|
|
17
|
-
{/if}
|
|
18
|
-
</IconButton>
|
|
11
|
+
<IconButton on:click={handleClick} variant="invisible">
|
|
12
|
+
{#if $dark}
|
|
13
|
+
<IconMoonStarsFill size={18} />
|
|
14
|
+
{:else}
|
|
15
|
+
<IconSunFill size={18} />
|
|
16
|
+
{/if}
|
|
17
|
+
</IconButton>
|