@prokodo/ui 0.1.11 → 0.1.13
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/README.md +6 -1
- package/dist/components/RTE/RTE.client.js +46 -5
- package/dist/components/RTE/RTE.css +226 -6
- package/dist/components/RTE/RTE.module.css +226 -6
- package/dist/components/RTE/RTE.module.scss.js +3 -0
- package/dist/components/RTE/RTE.utils.js +23 -1
- package/dist/components/accordion/Accordion.css +46 -0
- package/dist/components/accordion/Accordion.module.css +46 -0
- package/dist/components/accordion/Accordion.module.scss.js +4 -0
- package/dist/components/accordion/Accordion.view.js +25 -5
- package/dist/components/autocomplete/Autocomplete.client.js +132 -0
- package/dist/components/autocomplete/Autocomplete.css +317 -0
- package/dist/components/autocomplete/Autocomplete.js +12 -0
- package/dist/components/autocomplete/Autocomplete.lazy.js +12 -0
- package/dist/components/autocomplete/Autocomplete.module.css +317 -0
- package/dist/components/autocomplete/Autocomplete.module.scss.js +21 -0
- package/dist/components/autocomplete/Autocomplete.server.js +11 -0
- package/dist/components/autocomplete/Autocomplete.view.js +142 -0
- package/dist/components/autocomplete/index.js +4 -0
- package/dist/components/button/Button.css +1 -0
- package/dist/components/button/Button.module.css +1 -0
- package/dist/components/card/Card.css +9 -0
- package/dist/components/card/Card.module.css +9 -0
- package/dist/components/card/Card.module.scss.js +1 -0
- package/dist/components/dynamic-list/DynamicList.view.js +1 -1
- package/dist/components/input/Input.css +23 -4
- package/dist/components/input/Input.module.css +23 -4
- package/dist/components/pagination/Pagination.client.js +14 -0
- package/dist/components/pagination/Pagination.css +191 -0
- package/dist/components/pagination/Pagination.js +12 -0
- package/dist/components/pagination/Pagination.lazy.js +12 -0
- package/dist/components/pagination/Pagination.module.css +191 -0
- package/dist/components/pagination/Pagination.module.scss.js +12 -0
- package/dist/components/pagination/Pagination.server.js +11 -0
- package/dist/components/pagination/Pagination.utils.js +55 -0
- package/dist/components/pagination/Pagination.view.js +98 -0
- package/dist/components/pagination/index.js +4 -0
- package/dist/components/rich-text/RichText.css +0 -1
- package/dist/components/rich-text/RichText.module.css +0 -1
- package/dist/components/select/Select.client.js +230 -8
- package/dist/components/select/Select.css +47 -16
- package/dist/components/select/Select.module.css +47 -16
- package/dist/components/select/Select.module.scss.js +2 -0
- package/dist/components/select/Select.view.js +20 -57
- package/dist/components/switch/Switch.css +1 -1
- package/dist/components/switch/Switch.module.css +1 -1
- package/dist/components/switch/Switch.view.js +3 -1
- package/dist/components/tabs/Tabs.client.js +182 -0
- package/dist/components/tabs/Tabs.css +330 -0
- package/dist/components/tabs/Tabs.js +13 -0
- package/dist/components/tabs/Tabs.lazy.js +15 -0
- package/dist/components/tabs/Tabs.module.css +330 -0
- package/dist/components/tabs/Tabs.module.scss.js +19 -0
- package/dist/components/tabs/Tabs.server.js +11 -0
- package/dist/components/tabs/Tabs.view.js +157 -0
- package/dist/components/tabs/index.js +4 -0
- package/dist/components/tooltip/Tooltip.client.js +382 -0
- package/dist/components/tooltip/Tooltip.css +242 -0
- package/dist/components/tooltip/Tooltip.js +16 -0
- package/dist/components/tooltip/Tooltip.module.css +242 -0
- package/dist/components/tooltip/Tooltip.module.scss.js +15 -0
- package/dist/components/tooltip/Tooltip.server.js +12 -0
- package/dist/components/tooltip/Tooltip.view.js +127 -0
- package/dist/components/tooltip/index.js +4 -0
- package/dist/constants/project.js +1 -1
- package/dist/index.js +8 -0
- package/dist/theme.css +640 -22
- package/dist/tsconfig.build.tsbuildinfo +1 -1
- package/dist/types/components/RTE/RTE.utils.d.ts +1 -0
- package/dist/types/components/accordion/Accordion.d.ts +3 -0
- package/dist/types/components/accordion/Accordion.lazy.d.ts +3 -0
- package/dist/types/components/accordion/Accordion.model.d.ts +3 -0
- package/dist/types/components/accordion/Accordion.view.d.ts +1 -1
- package/dist/types/components/autocomplete/Autocomplete.client.d.ts +5 -0
- package/dist/types/components/autocomplete/Autocomplete.d.ts +4 -0
- package/dist/types/components/autocomplete/Autocomplete.lazy.d.ts +5 -0
- package/dist/types/components/autocomplete/Autocomplete.model.d.ts +58 -0
- package/dist/types/components/autocomplete/Autocomplete.server.d.ts +3 -0
- package/dist/types/components/autocomplete/Autocomplete.view.d.ts +3 -0
- package/dist/types/components/autocomplete/index.d.ts +2 -0
- package/dist/types/components/card/Card.model.d.ts +1 -1
- package/dist/types/components/grid/Grid.model.d.ts +37 -7
- package/dist/types/components/pagination/Pagination.client.d.ts +5 -0
- package/dist/types/components/pagination/Pagination.d.ts +4 -0
- package/dist/types/components/pagination/Pagination.lazy.d.ts +5 -0
- package/dist/types/components/pagination/Pagination.model.d.ts +22 -0
- package/dist/types/components/pagination/Pagination.server.d.ts +3 -0
- package/dist/types/components/pagination/Pagination.utils.d.ts +13 -0
- package/dist/types/components/pagination/Pagination.view.d.ts +3 -0
- package/dist/types/components/pagination/index.d.ts +2 -0
- package/dist/types/components/select/Select.model.d.ts +16 -1
- package/dist/types/components/tabs/Tabs.client.d.ts +5 -0
- package/dist/types/components/tabs/Tabs.d.ts +4 -0
- package/dist/types/components/tabs/Tabs.lazy.d.ts +5 -0
- package/dist/types/components/tabs/Tabs.model.d.ts +43 -0
- package/dist/types/components/tabs/Tabs.server.d.ts +3 -0
- package/dist/types/components/tabs/Tabs.view.d.ts +3 -0
- package/dist/types/components/tabs/index.d.ts +2 -0
- package/dist/types/components/tooltip/Tooltip.client.d.ts +5 -0
- package/dist/types/components/tooltip/Tooltip.d.ts +4 -0
- package/dist/types/components/tooltip/Tooltip.lazy.d.ts +5 -0
- package/dist/types/components/tooltip/Tooltip.model.d.ts +47 -0
- package/dist/types/components/tooltip/Tooltip.server.d.ts +3 -0
- package/dist/types/components/tooltip/Tooltip.view.d.ts +3 -0
- package/dist/types/components/tooltip/index.d.ts +2 -0
- package/dist/types/index.d.ts +4 -0
- package/package.json +23 -2
package/README.md
CHANGED
|
@@ -42,7 +42,7 @@
|
|
|
42
42
|
- ✨ **Adaptive Island Components (AIC)**: A rendering strategy where each component loads only the JavaScript it needs — when needed.
|
|
43
43
|
- ⚡️ **Modern stack**: Vite, React 19, TypeScript, and SCSS Modules
|
|
44
44
|
- 💅 **Design consistency**: Theming via design tokens and BEM-style naming
|
|
45
|
-
- 🧩 **Component-rich**:
|
|
45
|
+
- 🧩 **Component-rich**: 50+ reusable UI components
|
|
46
46
|
- 🧪 **Reliable**: Fully tested with Jest and Testing Library
|
|
47
47
|
- 📚 **Storybook**: Explore the components at [ui.prokodo.com](https://ui.prokodo.com)
|
|
48
48
|
- 📦 **Ready-to-install**: Distributed via npm for non-production use under the BUSL-1.1 license
|
|
@@ -161,6 +161,7 @@ export default function GalleryPage() {
|
|
|
161
161
|
| Accordion | ✅ | ✅ |
|
|
162
162
|
| Animated | ✅ | ✅ |
|
|
163
163
|
| AnimatedText | ✅ | ✅ |
|
|
164
|
+
| Autocomplete | ✅ | ✅ |
|
|
164
165
|
| Avatar | ✅ | ✅ |
|
|
165
166
|
| BaseLink | ✅ | ✅ |
|
|
166
167
|
| Button | ✅ | ✅ |
|
|
@@ -186,6 +187,7 @@ export default function GalleryPage() {
|
|
|
186
187
|
| Loading | ✅ | – |
|
|
187
188
|
| Lottie | ❌ | ✅ |
|
|
188
189
|
| Map | ❌ | ✅ |
|
|
190
|
+
| Pagination | ✅ | ✅ |
|
|
189
191
|
| PostItem | ✅ | ✅ |
|
|
190
192
|
| PostTeaser | ✅ | ✅ |
|
|
191
193
|
| PostWidget | ✅ | ✅ |
|
|
@@ -203,7 +205,9 @@ export default function GalleryPage() {
|
|
|
203
205
|
| Stepper | ✅ | ✅ |
|
|
204
206
|
| Switch | ✅ | ✅ |
|
|
205
207
|
| Table | ✅ | – |
|
|
208
|
+
| Tabs | ✅ | ✅ |
|
|
206
209
|
| Teaser | ✅ | - |
|
|
210
|
+
| Tooltip | ✅ | ✅ |
|
|
207
211
|
|
|
208
212
|
## Since Next.js 16
|
|
209
213
|
|
|
@@ -333,6 +337,7 @@ export default createLazyWrapper<NavbarProps>({
|
|
|
333
337
|
- [ ] Add more ✨ **fancy styling**, UI polish and properties
|
|
334
338
|
- [ ] Improve **accessibility** to meet **WCAG 2.2 AAA** standards
|
|
335
339
|
- [ ] Detailed Documentation about the components
|
|
340
|
+
- [x] Detailed Typescript-Model-Documentation about the components
|
|
336
341
|
|
|
337
342
|
## Examples (Next.js + Headless CMS)
|
|
338
343
|
|
|
@@ -11,9 +11,20 @@ import { isString, isNull } from "../../helpers/validations.js";
|
|
|
11
11
|
import styles from "./RTE.module.scss.js";
|
|
12
12
|
import { ensureQuillSnowStyles } from "./RTE.styles.js";
|
|
13
13
|
import cssText from "../../node_modules/.pnpm/quill@2.0.3/node_modules/quill/dist/quill.snow.css.js";
|
|
14
|
-
import { cleanupQuill, addClasses, decorateToolbar } from "./RTE.utils.js";
|
|
14
|
+
import { cleanupQuill, addClasses, decorateToolbar, syncPickerSelected } from "./RTE.utils.js";
|
|
15
15
|
import { RTEView } from "./RTE.view.js";
|
|
16
16
|
const bem = create(styles, "RTE");
|
|
17
|
+
const ALLOWED_FORMATS = [
|
|
18
|
+
"header",
|
|
19
|
+
"bold",
|
|
20
|
+
"italic",
|
|
21
|
+
"underline",
|
|
22
|
+
"strike",
|
|
23
|
+
"list",
|
|
24
|
+
"link",
|
|
25
|
+
"code-block",
|
|
26
|
+
"image"
|
|
27
|
+
];
|
|
17
28
|
function RTEClient(props) {
|
|
18
29
|
const {
|
|
19
30
|
name,
|
|
@@ -126,7 +137,7 @@ function RTEClient(props) {
|
|
|
126
137
|
const mountEl = mountRef.current;
|
|
127
138
|
const surfaceEl = surfaceRef.current;
|
|
128
139
|
async function init() {
|
|
129
|
-
var _a, _b, _c, _d, _e;
|
|
140
|
+
var _a, _b, _c, _d, _e, _f;
|
|
130
141
|
if (!mountEl || !surfaceEl) return;
|
|
131
142
|
if (Boolean(disabled) || Boolean(readOnly)) return;
|
|
132
143
|
cleanupQuill(surfaceEl, mountEl);
|
|
@@ -171,6 +182,7 @@ function RTEClient(props) {
|
|
|
171
182
|
const opts = rteOptionsRef.current;
|
|
172
183
|
const extraToolbar = rteToolbarRef.current;
|
|
173
184
|
const baseToolbar = [
|
|
185
|
+
[{ header: [3, 4, false] }],
|
|
174
186
|
["bold", "italic", "underline", "strike"],
|
|
175
187
|
[{ list: "ordered" }, { list: "bullet" }],
|
|
176
188
|
["link", "code-block", "image"],
|
|
@@ -181,6 +193,7 @@ function RTEClient(props) {
|
|
|
181
193
|
...opts,
|
|
182
194
|
theme: "snow",
|
|
183
195
|
placeholder: placeholder ?? "",
|
|
196
|
+
formats: ALLOWED_FORMATS,
|
|
184
197
|
modules: {
|
|
185
198
|
history: {
|
|
186
199
|
delay: 1e3,
|
|
@@ -196,12 +209,40 @@ function RTEClient(props) {
|
|
|
196
209
|
}
|
|
197
210
|
});
|
|
198
211
|
quillRef.current = q;
|
|
199
|
-
|
|
212
|
+
const Keyboard = q.getModule("keyboard");
|
|
213
|
+
(_c = Keyboard == null ? void 0 : Keyboard.addBinding) == null ? void 0 : _c.call(
|
|
214
|
+
Keyboard,
|
|
215
|
+
{
|
|
216
|
+
key: 13,
|
|
217
|
+
// Enter
|
|
218
|
+
shiftKey: false,
|
|
219
|
+
collapsed: true
|
|
220
|
+
},
|
|
221
|
+
(range, ctx) => {
|
|
222
|
+
var _a2;
|
|
223
|
+
const header = (_a2 = ctx == null ? void 0 : ctx.format) == null ? void 0 : _a2.header;
|
|
224
|
+
if (!header) return true;
|
|
225
|
+
q.insertText(range.index, "\n", "user");
|
|
226
|
+
q.formatLine(range.index + 1, 1, { header: false }, "user");
|
|
227
|
+
q.setSelection(range.index + 1, 0, "silent");
|
|
228
|
+
return false;
|
|
229
|
+
}
|
|
230
|
+
);
|
|
231
|
+
(_d = opts == null ? void 0 : opts.onInit) == null ? void 0 : _d.call(opts, q);
|
|
200
232
|
addClasses(q.root, bem("editor"));
|
|
201
233
|
const toolbarModule = q.getModule("toolbar");
|
|
202
234
|
addClasses((toolbarModule == null ? void 0 : toolbarModule.container) ?? null, bem("toolbar"));
|
|
203
235
|
const toolbarEl = (toolbarModule == null ? void 0 : toolbarModule.container) ?? null;
|
|
204
|
-
if (toolbarEl)
|
|
236
|
+
if (toolbarEl) {
|
|
237
|
+
decorateToolbar(toolbarEl);
|
|
238
|
+
syncPickerSelected(toolbarEl);
|
|
239
|
+
const obs = new MutationObserver(() => syncPickerSelected(toolbarEl));
|
|
240
|
+
obs.observe(toolbarEl, {
|
|
241
|
+
subtree: true,
|
|
242
|
+
attributes: true,
|
|
243
|
+
attributeFilter: ["class"]
|
|
244
|
+
});
|
|
245
|
+
}
|
|
205
246
|
const tooltipEl = q.container.querySelector(
|
|
206
247
|
".ql-tooltip"
|
|
207
248
|
);
|
|
@@ -215,7 +256,7 @@ function RTEClient(props) {
|
|
|
215
256
|
if (container && !container.style.height) container.style.height = "220px";
|
|
216
257
|
if (htmlRef.current)
|
|
217
258
|
q.clipboard.dangerouslyPasteHTML(htmlRef.current, "silent");
|
|
218
|
-
emitValidation(((
|
|
259
|
+
emitValidation(((_f = (_e = q.getText()) == null ? void 0 : _e.trim) == null ? void 0 : _f.call(_e)) ?? "");
|
|
219
260
|
q.on("text-change", (_d2, _o, source) => {
|
|
220
261
|
if (source === "user") syncFromQuill();
|
|
221
262
|
});
|
|
@@ -151,6 +151,104 @@
|
|
|
151
151
|
fill: var(--color-grey-900) !important;
|
|
152
152
|
opacity: 0.7;
|
|
153
153
|
}
|
|
154
|
+
.prokodo-RTE__toolbar__picker__label {
|
|
155
|
+
position: relative;
|
|
156
|
+
padding-right: calc(0.5rem + 18px);
|
|
157
|
+
}
|
|
158
|
+
.prokodo-RTE__toolbar__picker__label::before {
|
|
159
|
+
content: "Normal";
|
|
160
|
+
color: var(--color-grey-900);
|
|
161
|
+
opacity: 0.85;
|
|
162
|
+
margin-right: 0.25rem;
|
|
163
|
+
white-space: nowrap;
|
|
164
|
+
font-weight: 400;
|
|
165
|
+
font-size: 1rem;
|
|
166
|
+
font-family: var(--font-secondary), -apple-system, system-ui, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
|
|
167
|
+
font-style: normal;
|
|
168
|
+
line-height: 1.45;
|
|
169
|
+
letter-spacing: 0.03em;
|
|
170
|
+
text-transform: none;
|
|
171
|
+
text-align: left;
|
|
172
|
+
text-decoration: none;
|
|
173
|
+
}
|
|
174
|
+
@media screen and (min-width: 480px) {
|
|
175
|
+
.prokodo-RTE__toolbar__picker__label::before {
|
|
176
|
+
font-size: 0.875rem;
|
|
177
|
+
line-height: 1.4;
|
|
178
|
+
}
|
|
179
|
+
}
|
|
180
|
+
@media screen and (min-width: 960px) {
|
|
181
|
+
.prokodo-RTE__toolbar__picker__label::before {
|
|
182
|
+
font-size: 0.875rem;
|
|
183
|
+
line-height: 1.4;
|
|
184
|
+
}
|
|
185
|
+
}
|
|
186
|
+
.prokodo-RTE__toolbar__picker__label[data-value="2"]::before {
|
|
187
|
+
content: "H2";
|
|
188
|
+
}
|
|
189
|
+
.prokodo-RTE__toolbar__picker__label[data-value="3"]::before {
|
|
190
|
+
content: "H3";
|
|
191
|
+
}
|
|
192
|
+
.prokodo-RTE__toolbar__picker__options {
|
|
193
|
+
margin-top: 0.25rem;
|
|
194
|
+
padding: 0.25rem;
|
|
195
|
+
border-radius: 14px;
|
|
196
|
+
background: var(--color-white) !important;
|
|
197
|
+
border-color: var(--color-grey-500) !important;
|
|
198
|
+
box-shadow: 0 10px 30px rgba(0, 0, 0, 0.12);
|
|
199
|
+
overflow: hidden;
|
|
200
|
+
min-width: 180px;
|
|
201
|
+
z-index: 20;
|
|
202
|
+
}
|
|
203
|
+
.prokodo-RTE__toolbar__picker__item {
|
|
204
|
+
border-radius: 12px;
|
|
205
|
+
padding: 0.25rem 0.5rem;
|
|
206
|
+
display: flex;
|
|
207
|
+
align-items: center;
|
|
208
|
+
cursor: pointer;
|
|
209
|
+
}
|
|
210
|
+
.prokodo-RTE__toolbar__picker__item::before {
|
|
211
|
+
content: "Normal";
|
|
212
|
+
color: var(--color-grey-900);
|
|
213
|
+
opacity: 0.85;
|
|
214
|
+
font-weight: 400;
|
|
215
|
+
font-size: 1rem;
|
|
216
|
+
font-family: var(--font-secondary), -apple-system, system-ui, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
|
|
217
|
+
font-style: normal;
|
|
218
|
+
line-height: 1.45;
|
|
219
|
+
letter-spacing: 0.03em;
|
|
220
|
+
text-transform: none;
|
|
221
|
+
text-align: left;
|
|
222
|
+
text-decoration: none;
|
|
223
|
+
}
|
|
224
|
+
@media screen and (min-width: 480px) {
|
|
225
|
+
.prokodo-RTE__toolbar__picker__item::before {
|
|
226
|
+
font-size: 0.875rem;
|
|
227
|
+
line-height: 1.4;
|
|
228
|
+
}
|
|
229
|
+
}
|
|
230
|
+
@media screen and (min-width: 960px) {
|
|
231
|
+
.prokodo-RTE__toolbar__picker__item::before {
|
|
232
|
+
font-size: 0.875rem;
|
|
233
|
+
line-height: 1.4;
|
|
234
|
+
}
|
|
235
|
+
}
|
|
236
|
+
.prokodo-RTE__toolbar__picker__item[data-value="2"]::before {
|
|
237
|
+
content: "H2";
|
|
238
|
+
}
|
|
239
|
+
.prokodo-RTE__toolbar__picker__item[data-value="3"]::before {
|
|
240
|
+
content: "H3";
|
|
241
|
+
}
|
|
242
|
+
.prokodo-RTE__toolbar__picker__item:hover {
|
|
243
|
+
background: var(--color-primary-50) !important;
|
|
244
|
+
}
|
|
245
|
+
.prokodo-RTE__toolbar__picker__item[data-selected=true] {
|
|
246
|
+
background: var(--color-primary-100) !important;
|
|
247
|
+
}
|
|
248
|
+
.prokodo-RTE__toolbar__picker__item:focus-visible {
|
|
249
|
+
outline: 2px solid var(--color-primary-100);
|
|
250
|
+
outline-offset: 2px;
|
|
251
|
+
}
|
|
154
252
|
.prokodo-RTE__resize {
|
|
155
253
|
position: absolute;
|
|
156
254
|
right: 0.5rem;
|
|
@@ -208,18 +306,18 @@
|
|
|
208
306
|
}
|
|
209
307
|
}
|
|
210
308
|
.prokodo-RTE__editor p {
|
|
211
|
-
margin: 0 0
|
|
309
|
+
margin: 0.75rem 0 !important;
|
|
212
310
|
}
|
|
213
311
|
.prokodo-RTE__editor p:last-child {
|
|
214
|
-
margin-bottom: 0;
|
|
312
|
+
margin-bottom: 0 !important;
|
|
215
313
|
}
|
|
216
314
|
.prokodo-RTE__editor ul,
|
|
217
315
|
.prokodo-RTE__editor ol {
|
|
218
|
-
margin: 0 0 0.5rem 1.25rem;
|
|
219
|
-
padding: 0;
|
|
316
|
+
margin: 0 0 0.5rem 1.25rem !important;
|
|
317
|
+
padding: 0 !important;
|
|
220
318
|
}
|
|
221
319
|
.prokodo-RTE__editor pre {
|
|
222
|
-
margin: 0.5rem 0;
|
|
320
|
+
margin: 0.5rem 0 !important;
|
|
223
321
|
padding: 0.5rem;
|
|
224
322
|
border-radius: 14px;
|
|
225
323
|
overflow: auto;
|
|
@@ -227,7 +325,7 @@
|
|
|
227
325
|
}
|
|
228
326
|
.prokodo-RTE__editor code {
|
|
229
327
|
background: rgba(0, 0, 0, 0.06);
|
|
230
|
-
padding: 0 6px;
|
|
328
|
+
padding: 0 6px !important;
|
|
231
329
|
border-radius: 8px;
|
|
232
330
|
}
|
|
233
331
|
.prokodo-RTE__editor img {
|
|
@@ -237,6 +335,128 @@
|
|
|
237
335
|
display: block;
|
|
238
336
|
margin: 0.5rem 0;
|
|
239
337
|
}
|
|
338
|
+
.prokodo-RTE__editor h1,
|
|
339
|
+
.prokodo-RTE__editor h2,
|
|
340
|
+
.prokodo-RTE__editor h3,
|
|
341
|
+
.prokodo-RTE__editor h4,
|
|
342
|
+
.prokodo-RTE__editor h5,
|
|
343
|
+
.prokodo-RTE__editor h6 {
|
|
344
|
+
margin: 1rem 0 0.5rem 0 !important;
|
|
345
|
+
}
|
|
346
|
+
.prokodo-RTE__editor > h1:first-child,
|
|
347
|
+
.prokodo-RTE__editor > h2:first-child,
|
|
348
|
+
.prokodo-RTE__editor > h3:first-child,
|
|
349
|
+
.prokodo-RTE__editor > h4:first-child,
|
|
350
|
+
.prokodo-RTE__editor > h5:first-child,
|
|
351
|
+
.prokodo-RTE__editor > h6:first-child {
|
|
352
|
+
margin-top: 0 !important;
|
|
353
|
+
}
|
|
354
|
+
.prokodo-RTE__editor h1 {
|
|
355
|
+
font-weight: 900;
|
|
356
|
+
font-size: 1.75rem;
|
|
357
|
+
font-family: var(--font-primary), -apple-system, system-ui, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
|
|
358
|
+
font-style: normal;
|
|
359
|
+
line-height: 1.6;
|
|
360
|
+
letter-spacing: 0.03em;
|
|
361
|
+
text-transform: none;
|
|
362
|
+
text-align: left;
|
|
363
|
+
text-decoration: none;
|
|
364
|
+
}
|
|
365
|
+
@media screen and (min-width: 480px) {
|
|
366
|
+
.prokodo-RTE__editor h1 {
|
|
367
|
+
font-size: 2.25rem;
|
|
368
|
+
}
|
|
369
|
+
}
|
|
370
|
+
@media screen and (min-width: 960px) {
|
|
371
|
+
.prokodo-RTE__editor h1 {
|
|
372
|
+
font-size: 2.75rem;
|
|
373
|
+
}
|
|
374
|
+
}
|
|
375
|
+
.prokodo-RTE__editor h2 {
|
|
376
|
+
font-weight: 700;
|
|
377
|
+
font-size: 1.5rem;
|
|
378
|
+
font-family: var(--font-primary), -apple-system, system-ui, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
|
|
379
|
+
font-style: normal;
|
|
380
|
+
line-height: 1.55;
|
|
381
|
+
letter-spacing: 0.03em;
|
|
382
|
+
text-transform: none;
|
|
383
|
+
text-align: left;
|
|
384
|
+
text-decoration: none;
|
|
385
|
+
}
|
|
386
|
+
@media screen and (min-width: 480px) {
|
|
387
|
+
.prokodo-RTE__editor h2 {
|
|
388
|
+
font-size: 1.75rem;
|
|
389
|
+
}
|
|
390
|
+
}
|
|
391
|
+
@media screen and (min-width: 960px) {
|
|
392
|
+
.prokodo-RTE__editor h2 {
|
|
393
|
+
font-size: 2.25rem;
|
|
394
|
+
}
|
|
395
|
+
}
|
|
396
|
+
.prokodo-RTE__editor h3 {
|
|
397
|
+
font-weight: 500;
|
|
398
|
+
font-size: 1.5rem;
|
|
399
|
+
font-family: var(--font-primary), -apple-system, system-ui, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
|
|
400
|
+
font-style: normal;
|
|
401
|
+
line-height: 1.5;
|
|
402
|
+
letter-spacing: 0.03em;
|
|
403
|
+
text-transform: none;
|
|
404
|
+
text-align: left;
|
|
405
|
+
text-decoration: none;
|
|
406
|
+
}
|
|
407
|
+
@media screen and (min-width: 480px) {
|
|
408
|
+
.prokodo-RTE__editor h3 {
|
|
409
|
+
font-size: 1.5rem;
|
|
410
|
+
}
|
|
411
|
+
}
|
|
412
|
+
@media screen and (min-width: 960px) {
|
|
413
|
+
.prokodo-RTE__editor h3 {
|
|
414
|
+
font-size: 1.75rem;
|
|
415
|
+
}
|
|
416
|
+
}
|
|
417
|
+
.prokodo-RTE__editor h4 {
|
|
418
|
+
font-weight: 400;
|
|
419
|
+
font-size: 1.125rem;
|
|
420
|
+
font-family: var(--font-primary), -apple-system, system-ui, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
|
|
421
|
+
font-style: normal;
|
|
422
|
+
line-height: 1.5;
|
|
423
|
+
letter-spacing: 0.03em;
|
|
424
|
+
text-transform: none;
|
|
425
|
+
text-align: left;
|
|
426
|
+
text-decoration: none;
|
|
427
|
+
}
|
|
428
|
+
@media screen and (min-width: 480px) {
|
|
429
|
+
.prokodo-RTE__editor h4 {
|
|
430
|
+
font-size: 1.5rem;
|
|
431
|
+
}
|
|
432
|
+
}
|
|
433
|
+
@media screen and (min-width: 960px) {
|
|
434
|
+
.prokodo-RTE__editor h4 {
|
|
435
|
+
font-size: 1.5rem;
|
|
436
|
+
}
|
|
437
|
+
}
|
|
438
|
+
.prokodo-RTE__editor h5 {
|
|
439
|
+
font-weight: 400;
|
|
440
|
+
font-size: 1.125rem;
|
|
441
|
+
font-family: var(--font-primary), -apple-system, system-ui, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
|
|
442
|
+
font-style: normal;
|
|
443
|
+
line-height: 1.45;
|
|
444
|
+
letter-spacing: 0.03em;
|
|
445
|
+
text-transform: none;
|
|
446
|
+
text-align: left;
|
|
447
|
+
text-decoration: none;
|
|
448
|
+
}
|
|
449
|
+
.prokodo-RTE__editor h6 {
|
|
450
|
+
font-weight: 400;
|
|
451
|
+
font-size: 1rem;
|
|
452
|
+
font-family: var(--font-primary), -apple-system, system-ui, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
|
|
453
|
+
font-style: normal;
|
|
454
|
+
line-height: 1.4;
|
|
455
|
+
letter-spacing: 0.03em;
|
|
456
|
+
text-transform: none;
|
|
457
|
+
text-align: left;
|
|
458
|
+
text-decoration: none;
|
|
459
|
+
}
|
|
240
460
|
.prokodo-RTE--disabled {
|
|
241
461
|
opacity: 0.9;
|
|
242
462
|
}
|
|
@@ -151,6 +151,104 @@
|
|
|
151
151
|
fill: var(--color-grey-900) !important;
|
|
152
152
|
opacity: 0.7;
|
|
153
153
|
}
|
|
154
|
+
.prokodo-RTE__toolbar__picker__label {
|
|
155
|
+
position: relative;
|
|
156
|
+
padding-right: calc(0.5rem + 18px);
|
|
157
|
+
}
|
|
158
|
+
.prokodo-RTE__toolbar__picker__label::before {
|
|
159
|
+
content: "Normal";
|
|
160
|
+
color: var(--color-grey-900);
|
|
161
|
+
opacity: 0.85;
|
|
162
|
+
margin-right: 0.25rem;
|
|
163
|
+
white-space: nowrap;
|
|
164
|
+
font-weight: 400;
|
|
165
|
+
font-size: 1rem;
|
|
166
|
+
font-family: var(--font-secondary), -apple-system, system-ui, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
|
|
167
|
+
font-style: normal;
|
|
168
|
+
line-height: 1.45;
|
|
169
|
+
letter-spacing: 0.03em;
|
|
170
|
+
text-transform: none;
|
|
171
|
+
text-align: left;
|
|
172
|
+
text-decoration: none;
|
|
173
|
+
}
|
|
174
|
+
@media screen and (min-width: 480px) {
|
|
175
|
+
.prokodo-RTE__toolbar__picker__label::before {
|
|
176
|
+
font-size: 0.875rem;
|
|
177
|
+
line-height: 1.4;
|
|
178
|
+
}
|
|
179
|
+
}
|
|
180
|
+
@media screen and (min-width: 960px) {
|
|
181
|
+
.prokodo-RTE__toolbar__picker__label::before {
|
|
182
|
+
font-size: 0.875rem;
|
|
183
|
+
line-height: 1.4;
|
|
184
|
+
}
|
|
185
|
+
}
|
|
186
|
+
.prokodo-RTE__toolbar__picker__label[data-value="2"]::before {
|
|
187
|
+
content: "H2";
|
|
188
|
+
}
|
|
189
|
+
.prokodo-RTE__toolbar__picker__label[data-value="3"]::before {
|
|
190
|
+
content: "H3";
|
|
191
|
+
}
|
|
192
|
+
.prokodo-RTE__toolbar__picker__options {
|
|
193
|
+
margin-top: 0.25rem;
|
|
194
|
+
padding: 0.25rem;
|
|
195
|
+
border-radius: 14px;
|
|
196
|
+
background: var(--color-white) !important;
|
|
197
|
+
border-color: var(--color-grey-500) !important;
|
|
198
|
+
box-shadow: 0 10px 30px rgba(0, 0, 0, 0.12);
|
|
199
|
+
overflow: hidden;
|
|
200
|
+
min-width: 180px;
|
|
201
|
+
z-index: 20;
|
|
202
|
+
}
|
|
203
|
+
.prokodo-RTE__toolbar__picker__item {
|
|
204
|
+
border-radius: 12px;
|
|
205
|
+
padding: 0.25rem 0.5rem;
|
|
206
|
+
display: flex;
|
|
207
|
+
align-items: center;
|
|
208
|
+
cursor: pointer;
|
|
209
|
+
}
|
|
210
|
+
.prokodo-RTE__toolbar__picker__item::before {
|
|
211
|
+
content: "Normal";
|
|
212
|
+
color: var(--color-grey-900);
|
|
213
|
+
opacity: 0.85;
|
|
214
|
+
font-weight: 400;
|
|
215
|
+
font-size: 1rem;
|
|
216
|
+
font-family: var(--font-secondary), -apple-system, system-ui, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
|
|
217
|
+
font-style: normal;
|
|
218
|
+
line-height: 1.45;
|
|
219
|
+
letter-spacing: 0.03em;
|
|
220
|
+
text-transform: none;
|
|
221
|
+
text-align: left;
|
|
222
|
+
text-decoration: none;
|
|
223
|
+
}
|
|
224
|
+
@media screen and (min-width: 480px) {
|
|
225
|
+
.prokodo-RTE__toolbar__picker__item::before {
|
|
226
|
+
font-size: 0.875rem;
|
|
227
|
+
line-height: 1.4;
|
|
228
|
+
}
|
|
229
|
+
}
|
|
230
|
+
@media screen and (min-width: 960px) {
|
|
231
|
+
.prokodo-RTE__toolbar__picker__item::before {
|
|
232
|
+
font-size: 0.875rem;
|
|
233
|
+
line-height: 1.4;
|
|
234
|
+
}
|
|
235
|
+
}
|
|
236
|
+
.prokodo-RTE__toolbar__picker__item[data-value="2"]::before {
|
|
237
|
+
content: "H2";
|
|
238
|
+
}
|
|
239
|
+
.prokodo-RTE__toolbar__picker__item[data-value="3"]::before {
|
|
240
|
+
content: "H3";
|
|
241
|
+
}
|
|
242
|
+
.prokodo-RTE__toolbar__picker__item:hover {
|
|
243
|
+
background: var(--color-primary-50) !important;
|
|
244
|
+
}
|
|
245
|
+
.prokodo-RTE__toolbar__picker__item[data-selected=true] {
|
|
246
|
+
background: var(--color-primary-100) !important;
|
|
247
|
+
}
|
|
248
|
+
.prokodo-RTE__toolbar__picker__item:focus-visible {
|
|
249
|
+
outline: 2px solid var(--color-primary-100);
|
|
250
|
+
outline-offset: 2px;
|
|
251
|
+
}
|
|
154
252
|
.prokodo-RTE__resize {
|
|
155
253
|
position: absolute;
|
|
156
254
|
right: 0.5rem;
|
|
@@ -208,18 +306,18 @@
|
|
|
208
306
|
}
|
|
209
307
|
}
|
|
210
308
|
.prokodo-RTE__editor p {
|
|
211
|
-
margin: 0 0
|
|
309
|
+
margin: 0.75rem 0 !important;
|
|
212
310
|
}
|
|
213
311
|
.prokodo-RTE__editor p:last-child {
|
|
214
|
-
margin-bottom: 0;
|
|
312
|
+
margin-bottom: 0 !important;
|
|
215
313
|
}
|
|
216
314
|
.prokodo-RTE__editor ul,
|
|
217
315
|
.prokodo-RTE__editor ol {
|
|
218
|
-
margin: 0 0 0.5rem 1.25rem;
|
|
219
|
-
padding: 0;
|
|
316
|
+
margin: 0 0 0.5rem 1.25rem !important;
|
|
317
|
+
padding: 0 !important;
|
|
220
318
|
}
|
|
221
319
|
.prokodo-RTE__editor pre {
|
|
222
|
-
margin: 0.5rem 0;
|
|
320
|
+
margin: 0.5rem 0 !important;
|
|
223
321
|
padding: 0.5rem;
|
|
224
322
|
border-radius: 14px;
|
|
225
323
|
overflow: auto;
|
|
@@ -227,7 +325,7 @@
|
|
|
227
325
|
}
|
|
228
326
|
.prokodo-RTE__editor code {
|
|
229
327
|
background: rgba(0, 0, 0, 0.06);
|
|
230
|
-
padding: 0 6px;
|
|
328
|
+
padding: 0 6px !important;
|
|
231
329
|
border-radius: 8px;
|
|
232
330
|
}
|
|
233
331
|
.prokodo-RTE__editor img {
|
|
@@ -237,6 +335,128 @@
|
|
|
237
335
|
display: block;
|
|
238
336
|
margin: 0.5rem 0;
|
|
239
337
|
}
|
|
338
|
+
.prokodo-RTE__editor h1,
|
|
339
|
+
.prokodo-RTE__editor h2,
|
|
340
|
+
.prokodo-RTE__editor h3,
|
|
341
|
+
.prokodo-RTE__editor h4,
|
|
342
|
+
.prokodo-RTE__editor h5,
|
|
343
|
+
.prokodo-RTE__editor h6 {
|
|
344
|
+
margin: 1rem 0 0.5rem 0 !important;
|
|
345
|
+
}
|
|
346
|
+
.prokodo-RTE__editor > h1:first-child,
|
|
347
|
+
.prokodo-RTE__editor > h2:first-child,
|
|
348
|
+
.prokodo-RTE__editor > h3:first-child,
|
|
349
|
+
.prokodo-RTE__editor > h4:first-child,
|
|
350
|
+
.prokodo-RTE__editor > h5:first-child,
|
|
351
|
+
.prokodo-RTE__editor > h6:first-child {
|
|
352
|
+
margin-top: 0 !important;
|
|
353
|
+
}
|
|
354
|
+
.prokodo-RTE__editor h1 {
|
|
355
|
+
font-weight: 900;
|
|
356
|
+
font-size: 1.75rem;
|
|
357
|
+
font-family: var(--font-primary), -apple-system, system-ui, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
|
|
358
|
+
font-style: normal;
|
|
359
|
+
line-height: 1.6;
|
|
360
|
+
letter-spacing: 0.03em;
|
|
361
|
+
text-transform: none;
|
|
362
|
+
text-align: left;
|
|
363
|
+
text-decoration: none;
|
|
364
|
+
}
|
|
365
|
+
@media screen and (min-width: 480px) {
|
|
366
|
+
.prokodo-RTE__editor h1 {
|
|
367
|
+
font-size: 2.25rem;
|
|
368
|
+
}
|
|
369
|
+
}
|
|
370
|
+
@media screen and (min-width: 960px) {
|
|
371
|
+
.prokodo-RTE__editor h1 {
|
|
372
|
+
font-size: 2.75rem;
|
|
373
|
+
}
|
|
374
|
+
}
|
|
375
|
+
.prokodo-RTE__editor h2 {
|
|
376
|
+
font-weight: 700;
|
|
377
|
+
font-size: 1.5rem;
|
|
378
|
+
font-family: var(--font-primary), -apple-system, system-ui, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
|
|
379
|
+
font-style: normal;
|
|
380
|
+
line-height: 1.55;
|
|
381
|
+
letter-spacing: 0.03em;
|
|
382
|
+
text-transform: none;
|
|
383
|
+
text-align: left;
|
|
384
|
+
text-decoration: none;
|
|
385
|
+
}
|
|
386
|
+
@media screen and (min-width: 480px) {
|
|
387
|
+
.prokodo-RTE__editor h2 {
|
|
388
|
+
font-size: 1.75rem;
|
|
389
|
+
}
|
|
390
|
+
}
|
|
391
|
+
@media screen and (min-width: 960px) {
|
|
392
|
+
.prokodo-RTE__editor h2 {
|
|
393
|
+
font-size: 2.25rem;
|
|
394
|
+
}
|
|
395
|
+
}
|
|
396
|
+
.prokodo-RTE__editor h3 {
|
|
397
|
+
font-weight: 500;
|
|
398
|
+
font-size: 1.5rem;
|
|
399
|
+
font-family: var(--font-primary), -apple-system, system-ui, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
|
|
400
|
+
font-style: normal;
|
|
401
|
+
line-height: 1.5;
|
|
402
|
+
letter-spacing: 0.03em;
|
|
403
|
+
text-transform: none;
|
|
404
|
+
text-align: left;
|
|
405
|
+
text-decoration: none;
|
|
406
|
+
}
|
|
407
|
+
@media screen and (min-width: 480px) {
|
|
408
|
+
.prokodo-RTE__editor h3 {
|
|
409
|
+
font-size: 1.5rem;
|
|
410
|
+
}
|
|
411
|
+
}
|
|
412
|
+
@media screen and (min-width: 960px) {
|
|
413
|
+
.prokodo-RTE__editor h3 {
|
|
414
|
+
font-size: 1.75rem;
|
|
415
|
+
}
|
|
416
|
+
}
|
|
417
|
+
.prokodo-RTE__editor h4 {
|
|
418
|
+
font-weight: 400;
|
|
419
|
+
font-size: 1.125rem;
|
|
420
|
+
font-family: var(--font-primary), -apple-system, system-ui, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
|
|
421
|
+
font-style: normal;
|
|
422
|
+
line-height: 1.5;
|
|
423
|
+
letter-spacing: 0.03em;
|
|
424
|
+
text-transform: none;
|
|
425
|
+
text-align: left;
|
|
426
|
+
text-decoration: none;
|
|
427
|
+
}
|
|
428
|
+
@media screen and (min-width: 480px) {
|
|
429
|
+
.prokodo-RTE__editor h4 {
|
|
430
|
+
font-size: 1.5rem;
|
|
431
|
+
}
|
|
432
|
+
}
|
|
433
|
+
@media screen and (min-width: 960px) {
|
|
434
|
+
.prokodo-RTE__editor h4 {
|
|
435
|
+
font-size: 1.5rem;
|
|
436
|
+
}
|
|
437
|
+
}
|
|
438
|
+
.prokodo-RTE__editor h5 {
|
|
439
|
+
font-weight: 400;
|
|
440
|
+
font-size: 1.125rem;
|
|
441
|
+
font-family: var(--font-primary), -apple-system, system-ui, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
|
|
442
|
+
font-style: normal;
|
|
443
|
+
line-height: 1.45;
|
|
444
|
+
letter-spacing: 0.03em;
|
|
445
|
+
text-transform: none;
|
|
446
|
+
text-align: left;
|
|
447
|
+
text-decoration: none;
|
|
448
|
+
}
|
|
449
|
+
.prokodo-RTE__editor h6 {
|
|
450
|
+
font-weight: 400;
|
|
451
|
+
font-size: 1rem;
|
|
452
|
+
font-family: var(--font-primary), -apple-system, system-ui, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
|
|
453
|
+
font-style: normal;
|
|
454
|
+
line-height: 1.4;
|
|
455
|
+
letter-spacing: 0.03em;
|
|
456
|
+
text-transform: none;
|
|
457
|
+
text-align: left;
|
|
458
|
+
text-decoration: none;
|
|
459
|
+
}
|
|
240
460
|
.prokodo-RTE--disabled {
|
|
241
461
|
opacity: 0.9;
|
|
242
462
|
}
|
|
@@ -5,6 +5,9 @@ const styles = {
|
|
|
5
5
|
"prokodo-RTE__toolbar__icon__part__stroke": "prokodo-RTE__toolbar__icon__part__stroke",
|
|
6
6
|
"prokodo-RTE__toolbar__icon__part__stroke__miter": "prokodo-RTE__toolbar__icon__part__stroke__miter",
|
|
7
7
|
"prokodo-RTE__toolbar__icon__part__fill": "prokodo-RTE__toolbar__icon__part__fill",
|
|
8
|
+
"prokodo-RTE__toolbar__picker__label": "prokodo-RTE__toolbar__picker__label",
|
|
9
|
+
"prokodo-RTE__toolbar__picker__options": "prokodo-RTE__toolbar__picker__options",
|
|
10
|
+
"prokodo-RTE__toolbar__picker__item": "prokodo-RTE__toolbar__picker__item",
|
|
8
11
|
"prokodo-RTE__resize": "prokodo-RTE__resize",
|
|
9
12
|
"prokodo-RTE__mount": "prokodo-RTE__mount",
|
|
10
13
|
"prokodo-RTE__mount--disabled": "prokodo-RTE__mount--disabled",
|