@sparkle-learning/core 0.0.43 → 0.0.46

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.
Files changed (40) hide show
  1. package/dist/cjs/header-mobile-collapse_61.cjs.entry.js +10 -110
  2. package/dist/cjs/{icons-c61db785.js → icons-fda820af.js} +0 -0
  3. package/dist/cjs/sparkle-animation-player.cjs.entry.js +0 -1
  4. package/dist/cjs/sparkle-code.cjs.entry.js +1 -1
  5. package/dist/cjs/sparkle-menu-collapsible.cjs.entry.js +1 -1
  6. package/dist/collection/components/sparkle-animation-player/sparkle-animation-player.js +0 -1
  7. package/dist/collection/components/sparkle-root/sparkle-root.css +3 -0
  8. package/dist/esm/header-mobile-collapse_61.entry.js +12 -112
  9. package/dist/esm/{icons-9b62a1ec.js → icons-1c794c74.js} +0 -0
  10. package/dist/esm/sparkle-animation-player.entry.js +0 -1
  11. package/dist/esm/sparkle-code.entry.js +1 -1
  12. package/dist/esm/sparkle-menu-collapsible.entry.js +1 -1
  13. package/dist/node_modules/@sparkle-learning/components/dist/collection/components/button/button.css +49 -0
  14. package/dist/node_modules/@sparkle-learning/components/dist/collection/components/cards/card/card.css +208 -0
  15. package/dist/node_modules/@sparkle-learning/components/dist/collection/components/cards/cards.css +31 -0
  16. package/dist/node_modules/@sparkle-learning/components/dist/collection/components/code/code.css +245 -0
  17. package/dist/node_modules/@sparkle-learning/components/dist/collection/components/dropdown/dropdown.css +115 -0
  18. package/dist/node_modules/@sparkle-learning/components/dist/collection/components/header/header-mobile-collapse/header-mobile-collapse.css +255 -0
  19. package/dist/node_modules/@sparkle-learning/components/dist/collection/components/header/header.css +232 -0
  20. package/dist/node_modules/@sparkle-learning/components/dist/collection/components/menu/collapsible/collapsible.css +3 -0
  21. package/dist/node_modules/@sparkle-learning/components/dist/collection/components/menu/menu-toggle/menu-toggle.css +25 -0
  22. package/dist/node_modules/@sparkle-learning/components/dist/collection/components/menu/menu.css +71 -0
  23. package/dist/node_modules/@sparkle-learning/components/dist/collection/components/nav/nav.css +194 -0
  24. package/dist/node_modules/@sparkle-learning/components/dist/collection/components/notfound-page/notfound-page.css +4 -0
  25. package/dist/node_modules/@sparkle-learning/components/dist/collection/components/overlay/overlay.css +67 -0
  26. package/dist/node_modules/@sparkle-learning/components/dist/collection/components/page-footer/page-footer.css +18 -0
  27. package/dist/node_modules/@sparkle-learning/components/dist/collection/components/pagination/pagination.css +93 -0
  28. package/dist/node_modules/@sparkle-learning/components/dist/collection/components/select/select.css +52 -0
  29. package/dist/node_modules/@sparkle-learning/components/dist/collection/components/sidebar/sidebar.css +98 -0
  30. package/dist/node_modules/@sparkle-learning/components/dist/collection/components/sparkle-lower-content-nav/sparkle-lower-content-nav.css +8 -0
  31. package/dist/node_modules/@sparkle-learning/components/dist/collection/components/table-of-contents/table-of-contents.css +37 -0
  32. package/dist/node_modules/@sparkle-learning/components/dist/collection/components/tabs/tabs.css +64 -0
  33. package/dist/sparkle-core/{p-0fa3fd63.entry.js → p-11a6c175.entry.js} +1 -1
  34. package/dist/sparkle-core/p-41a9ece7.entry.js +1 -0
  35. package/dist/sparkle-core/{p-a102341e.entry.js → p-957715c5.entry.js} +1 -1
  36. package/dist/sparkle-core/{p-b401b101.entry.js → p-a465598d.entry.js} +26 -30
  37. package/dist/sparkle-core/{p-e8073714.js → p-cabe9139.js} +0 -0
  38. package/dist/sparkle-core/sparkle-core.esm.js +1 -1
  39. package/package.json +2 -2
  40. package/dist/sparkle-core/p-18cdd458.entry.js +0 -1
@@ -0,0 +1,208 @@
1
+ sparkle-card {
2
+ display: block;
3
+ font-size: 12px;
4
+ max-width: 30em;
5
+ }
6
+
7
+ .Card {
8
+ background-color: var(--background);
9
+ border-radius: 4px;
10
+ box-shadow: 0px 0.175em 0.5em rgba(2, 8, 20, 0.1), 0px 0.085em 0.175em rgba(2, 8, 20, 0.08);
11
+ color: var(--text-color--light);
12
+ display: flex;
13
+ flex-direction: column;
14
+ font-size: inherit;
15
+ font-weight: normal;
16
+ height: 100%;
17
+ justify-content: flex-start;
18
+ line-height: 1.6;
19
+ transition: box-shadow 150ms ease, transform 150ms ease;
20
+ width: 100%;
21
+ overflow: hidden;
22
+ }
23
+
24
+ .Card-with-image {
25
+ grid-row: span 2;
26
+ }
27
+
28
+ .Card-without-image {
29
+ font-size: 12px;
30
+ }
31
+
32
+ .Card-container {
33
+ padding: 1.65em 2em 1.65em;
34
+ }
35
+
36
+ .Card-image {
37
+ width: 100%;
38
+ height: auto;
39
+ }
40
+
41
+ .Card-icon,
42
+ .Card-iconset__container {
43
+ width: 48px;
44
+ height: 48px;
45
+
46
+ margin-bottom: 1.2em;
47
+
48
+ border-radius: 50%;
49
+ object-fit: cover;
50
+ background: rgb(246, 248, 251);
51
+ }
52
+
53
+ .Card-icon-hover {
54
+ display: none;
55
+ }
56
+
57
+ .Card-iconset__container {
58
+ position: relative;
59
+ }
60
+
61
+ .Card-iconset__container .Card-icon {
62
+ position: absolute;
63
+ opacity: 0;
64
+ transition: 0.8s opacity;
65
+ }
66
+
67
+ .Card-iconset__container .Card-icon--active {
68
+ opacity: 1;
69
+ }
70
+
71
+ .Card-ionicon {
72
+ width: 48px;
73
+ height: 48px;
74
+ float: left;
75
+ margin-right: 1em;
76
+ }
77
+
78
+ @media (hover: hover) {
79
+ .Card[href]:hover {
80
+ box-shadow: 0 0.35em 1.175em rgba(2, 8, 20, 0.1), 0 0.175em 0.5em rgba(2, 8, 20, 0.08);
81
+ transform: translateY(-1px);
82
+ }
83
+
84
+ .Card[href]:hover .Card-icon-default {
85
+ display: none;
86
+ }
87
+
88
+ .Card[href]:hover .Card-icon-hover {
89
+ display: block;
90
+ }
91
+ }
92
+
93
+ .Card-content > *:first-child {
94
+ margin-top: 0;
95
+ }
96
+
97
+ .Card-content > *:last-child {
98
+ margin-bottom: 0;
99
+ }
100
+
101
+ .Card-content > * {
102
+ margin: 0 0 0.65em;
103
+ }
104
+
105
+ .Card-header {
106
+ color: var(--text-color--dark);
107
+ font-size: 1.4em;
108
+ font-weight: 500;
109
+ line-height: 1.4;
110
+ margin-bottom: 0.45em;
111
+ }
112
+
113
+ .Card-without-image .Card-header {
114
+ margin-bottom: 0.3em;
115
+ }
116
+
117
+ .Card-header > svg {
118
+ fill: currentColor;
119
+ height: 1em;
120
+ margin-bottom: -0.125em;
121
+ width: auto;
122
+ }
123
+
124
+ .Card-size-lg {
125
+ font-size: 14px;
126
+ }
127
+
128
+ .Card-size-lg .Card-icon,
129
+ .Card-size-lg .Card-ionicon,
130
+ .Card-size-lg .Card-iconset__container {
131
+ width: 80px;
132
+ height: 80px;
133
+ }
134
+
135
+ .Card-size-lg.Card-without-image .Card-header {
136
+ font-size: 20px;
137
+ }
138
+
139
+ sparkle-card.disabled,
140
+ sparkle-card[disabled] {
141
+ position: relative;
142
+ }
143
+
144
+ sparkle-card.disabled::after,
145
+ sparkle-card[disabled]::after {
146
+ position: absolute;
147
+ top: 0;
148
+ right: 0;
149
+ left: 0;
150
+ bottom: 0;
151
+ background: rgba(232, 232, 232, 0.5);
152
+ pointer-events: none;
153
+ content: '';
154
+ }
155
+
156
+ aside sparkle-card {
157
+ max-width: 240px;
158
+ }
159
+
160
+ aside .Card-container {
161
+ display: grid;
162
+ grid-template-columns: minmax(0, max-content) 1fr;
163
+ grid-template-rows: minmax(0, min-content);
164
+ grid-template-areas:
165
+ 'icon title'
166
+ 'icon body';
167
+ }
168
+
169
+ aside .Card-icon {
170
+ width: 32px;
171
+ height: 32px;
172
+ margin-right: 16px;
173
+ margin-bottom: 0;
174
+ grid-area: icon;
175
+ }
176
+
177
+ aside .Card-header {
178
+ grid-area: title;
179
+ }
180
+
181
+ aside .Card-header::after {
182
+ background-image: url('/docs/assets/img/new-tab.svg');
183
+ display: inline-block;
184
+ height: 13px;
185
+ width: 13px;
186
+ background-size: 13px 13px;
187
+ margin-left: 4px;
188
+ content: '';
189
+ }
190
+
191
+ aside .Card-content {
192
+ grid-area: body;
193
+ /* https://stackoverflow.com/questions/5269713/css-ellipsis-on-second-line */
194
+ max-height: 42px;
195
+ overflow: hidden;
196
+ text-overflow: ellipsis;
197
+ display: -webkit-box;
198
+ -webkit-line-clamp: 2;
199
+ -webkit-box-orient: vertical;
200
+ }
201
+
202
+ aside .Card-icon + .Card-content {
203
+ margin-top: -6px;
204
+ }
205
+
206
+ .markdown-content p sparkle-card {
207
+ margin-top: 1em;
208
+ }
@@ -0,0 +1,31 @@
1
+ sparkle-cards {
2
+ display: grid;
3
+ font-size: 12px;
4
+ grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
5
+ grid-gap: 1.35rem;
6
+ }
7
+
8
+ sparkle-cards > sparkle-card {
9
+ font-size: inherit;
10
+ max-width: none;
11
+ }
12
+
13
+ sparkle-cards > sparkle-card.tall {
14
+ grid-row: span 2;
15
+ }
16
+
17
+ sparkle-cards > sparkle-card.wide {
18
+ grid-column: span 2;
19
+ }
20
+
21
+ sparkle-cards.prioritized > sparkle-card:nth-child(-n + 5) {
22
+ font-size: 1.25em;
23
+ }
24
+
25
+ sparkle-cards.prioritized > sparkle-card:first-child {
26
+ grid-row: span 2;
27
+ }
28
+
29
+ sparkle-cards.max-measure > sparkle-card {
30
+ max-width: 50%;
31
+ }
@@ -0,0 +1,245 @@
1
+ /**
2
+ * prism.js Dark theme for JavaScript, CSS and HTML
3
+ * Based on the slides of the talk “/Reg(exp){2}lained/”
4
+ * @author Lea Verou
5
+ */
6
+
7
+ code[class*="language-"],
8
+ pre[class*="language-"] {
9
+ color: #4d4d4c;
10
+ background: none;
11
+ white-space: pre;
12
+ word-spacing: normal;
13
+ word-break: normal;
14
+ word-wrap: normal;
15
+ line-height: 1.5;
16
+
17
+ -moz-tab-size: 4;
18
+ -o-tab-size: 4;
19
+ tab-size: 4;
20
+
21
+ -webkit-hyphens: none;
22
+ -moz-hyphens: none;
23
+ -ms-hyphens: none;
24
+ hyphens: none;
25
+ }
26
+
27
+ pre[class*="language-"],
28
+ :not(pre) > code[class*="language-"] {
29
+ background: hsl(30, 20%, 25%);
30
+ }
31
+
32
+ /* Code blocks */
33
+ pre[class*="language-"] {
34
+ padding: 1em;
35
+ margin: .5em 0;
36
+ overflow: auto;
37
+ border: .3em solid hsl(30, 20%, 40%);
38
+ border-radius: .5em;
39
+ box-shadow: 1px 1px .5em black inset;
40
+ }
41
+
42
+ /* Inline code */
43
+ :not(pre) > code[class*="language-"] {
44
+ padding: .15em .2em .05em;
45
+ border-radius: .3em;
46
+ border: .13em solid hsl(30, 20%, 40%);
47
+ box-shadow: 1px 1px .3em -.1em black inset;
48
+ white-space: normal;
49
+ }
50
+
51
+ /* Tomorrow Comment */
52
+ .token.comment,
53
+ .token.prolog,
54
+ .token.doctype,
55
+ .token.cdata {
56
+ color: #8c9296;
57
+ }
58
+
59
+ .token.punctuation {
60
+ opacity: .7;
61
+ }
62
+
63
+ .namespace {
64
+ opacity: .7;
65
+ }
66
+
67
+ .token.tag {
68
+ color: #91c5ff;
69
+ }
70
+
71
+ .token.tag .token.tag {
72
+ color: #2b90ff;
73
+ }
74
+
75
+ .token.property,
76
+ .token.attr-name,
77
+ .token.boolean,
78
+ .token.number,
79
+ .token.constant,
80
+ .token.symbol {
81
+ color: #8454ff;
82
+ }
83
+
84
+ .token.selector,
85
+ .token.char,
86
+ .token.function,
87
+ .token.builtin,
88
+ .token.inserted {
89
+ color: #ff6810;
90
+ }
91
+
92
+ .token.operator,
93
+ .token.string,
94
+ .token.entity,
95
+ .token.url,
96
+ .token.attr-value,
97
+ .language-css .token.string,
98
+ .style .token.string,
99
+ .token.variable {
100
+ color: #42b983;
101
+ }
102
+
103
+ .token.atrule {
104
+ color: #ffbb01;
105
+ }
106
+
107
+ .token.regex,
108
+ .token.keyword,
109
+ .token.important {
110
+ color: #f55073;
111
+ }
112
+
113
+ .token.important,
114
+ .token.bold {
115
+ font-weight: bold;
116
+ }
117
+ .token.italic {
118
+ font-style: italic;
119
+ }
120
+
121
+ .token.entity {
122
+ cursor: help;
123
+ }
124
+
125
+ .token.deleted {
126
+ color: red;
127
+ }
128
+
129
+ sparkle-code[language="shell"] > pre {
130
+ background-color: var(--text-color--dark);
131
+ border-radius: 7px;
132
+ }
133
+
134
+ sparkle-code[language="shell"]:before {
135
+ display: none;
136
+ }
137
+
138
+ sparkle-code[language="shell"] code {
139
+ color: rgba(255, 255, 255, 0.7);
140
+ font-size: 13px;
141
+ }
142
+
143
+ sparkle-code[language="shell"] .token {
144
+ color: inherit;
145
+ }
146
+
147
+ sparkle-code[language="shell"] .token.prompt {
148
+ color: #fb96f9;
149
+ user-select: none;
150
+ }
151
+
152
+ sparkle-code[language="shell"] .token.comment {
153
+ color: rgba(255, 255, 255, 0.45);
154
+ }
155
+
156
+
157
+ sparkle-code {
158
+ display: block;
159
+ position: relative;
160
+ }
161
+
162
+ sparkle-code:before {
163
+ color: #bdc5d1;
164
+ content: attr(language);
165
+ font-family: var(--code-font-family);
166
+ font-size: 10px;
167
+ letter-spacing: 0.05em;
168
+ line-height: 1;
169
+ padding: 0.75em;
170
+ position: absolute;
171
+ right: 0;
172
+ text-transform: uppercase;
173
+ top: 0;
174
+ }
175
+
176
+ sparkle-code[language="shell"] pre {
177
+ white-space: pre-wrap;
178
+ }
179
+
180
+ .code-text__copy{
181
+ position: absolute;
182
+ right: 0;
183
+ top: -1.6rem;
184
+ height: 20px;
185
+ }
186
+
187
+ .code-text__copy-link,
188
+ .code-text__copy-confirmation {
189
+ padding: 4px 5px;
190
+ font-size: 12px;
191
+ line-height: 12px;
192
+ font-weight: 600;
193
+ position: absolute;
194
+ right: 0;
195
+ top: 0;
196
+ }
197
+
198
+ .code-text__copy-link {
199
+ transition:
200
+ 0.2s transform ,
201
+ 0.2s opacity,
202
+ 0.2s color;
203
+ color: #70A4FF;
204
+ background-color: #E0EEFF;
205
+ border-radius: 4px;
206
+ display: inline-block;
207
+ cursor: pointer;
208
+ opacity: 1;
209
+ transform: translate3d(0,0,0);
210
+ z-index: 5;
211
+ }
212
+
213
+ .code-text__copy-link:hover {
214
+ color: var(--blue);
215
+ }
216
+
217
+ .code-text__copy-confirmation {
218
+ transition:
219
+ 0.2s transform ,
220
+ 0.2s opacity;
221
+ color: #0ec254;
222
+ opacity: 0;
223
+ transform: translate3d(0,5px,0);
224
+ z-index: 1;
225
+ display: flex;
226
+ align-items: center;
227
+ height: 20px;
228
+ padding: 0;
229
+ }
230
+
231
+ .code-text__copy-confirmation svg {
232
+ fill: #0ec254;
233
+ margin-right: -4px;
234
+ }
235
+
236
+ .show-confirmation .code-text__copy-link {
237
+ opacity: 0;
238
+ transform: translate3d(0,-5px,0);
239
+ pointer-events: none;
240
+ }
241
+
242
+ .show-confirmation .code-text__copy-confirmation {
243
+ opacity: 1;
244
+ transform: translate3d(0,0,0);
245
+ }
@@ -0,0 +1,115 @@
1
+ .Dropdown {
2
+ display: inline-block;
3
+ position: relative;
4
+ z-index: 1;
5
+ }
6
+
7
+ .Dropdown-button {
8
+ appearance: none;
9
+ background: none;
10
+ border: none;
11
+ color: inherit;
12
+ font-family: inherit;
13
+ font-size: inherit;
14
+ font-weight: inherit;
15
+ line-height: inherit;
16
+ padding: initial;
17
+ white-space: nowrap;
18
+ display: flex;
19
+ }
20
+
21
+ .Dropdown-button .Dropdown-icon {
22
+ height: 14px;
23
+ width: 22px;
24
+ fill: #ced6e0;
25
+ }
26
+
27
+ .Dropdown-button .Dropdown-icon + .Dropdown-arrow {
28
+ margin-left: 0px;
29
+ fill: #ced6e0;
30
+ vertical-align: 2px;
31
+ }
32
+ .Dropdown:focus,
33
+ .Dropdown-button:focus {
34
+ outline: none;
35
+ }
36
+
37
+ .Dropdown-button:hover {
38
+ cursor: pointer;
39
+ }
40
+
41
+ .Dropdown-arrow {
42
+ fill: currentColor;
43
+ height: 0.8em;
44
+ margin-bottom: -0.0875em;
45
+ width: 0.8em;
46
+ margin-left: 0.8em;
47
+ }
48
+
49
+ .Dropdown.is-open .Dropdown-arrow {
50
+ transform: rotate(180deg);
51
+ }
52
+
53
+ .Dropdown-panel {
54
+ background-color: var(--background);
55
+ border-radius: 6px;
56
+ border: none;
57
+ box-shadow: 0px 4px 12px 0px rgba(0, 0, 0, 0.08), 0px 2px 4px 0px rgba(0, 0, 0, 0.08);
58
+ display: none;
59
+ min-width: 100%;
60
+ overflow: hidden;
61
+ pointer-events: none;
62
+ position: absolute;
63
+ top: 100%;
64
+ visibility: hidden;
65
+ }
66
+
67
+ .Dropdown.is-open .Dropdown-panel {
68
+ display: initial;
69
+ pointer-events: auto;
70
+ visibility: visible;
71
+ }
72
+
73
+ .Dropdown--left .Dropdown-panel {
74
+ left: 0;
75
+ }
76
+
77
+ .Dropdown--right .Dropdown-panel {
78
+ right: 0;
79
+ }
80
+
81
+ .Dropdown--center .Dropdown-panel {
82
+ left: 50%;
83
+ transform: translateX(-50%);
84
+ }
85
+
86
+ .Dropdown-panel a {
87
+ display: flex;
88
+ justify-content: space-between;
89
+ padding: 0.5em 1em;
90
+ }
91
+
92
+ .Dropdown-panel svg {
93
+ height: 1em;
94
+ width: 1em;
95
+ margin-left: 4px;
96
+ }
97
+
98
+ @media (hover: hover) {
99
+ .Dropdown-panel a:hover {
100
+ background-color: rgba(0, 0, 0, 0.025);
101
+ }
102
+ }
103
+
104
+ .Dropdown-panel > section {
105
+ padding: 0.5em 0;
106
+ }
107
+
108
+ .Dropdown-panel > section:not(:last-child) {
109
+ border-bottom: solid 1px var(--line-rule-color);
110
+ }
111
+ .Dropdown-image {
112
+ height: 36px;
113
+ width: 36px;
114
+ border-radius: 50%;
115
+ }