@aicayzer/inkkit 0.5.0 → 0.6.1
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/chunks/{core-fEBASTpF.js → core-CbHV2KPY.js} +74 -3
- package/dist/chunks/{highlight-D3LQRB1-.js → highlight-C-9lbVMU.js} +1 -1
- package/dist/core.js +1 -1
- package/dist/editor.d.ts +2 -0
- package/dist/index.js +1 -1
- package/dist/style.css +71 -13
- package/dist/themes/calm.css +36 -0
- package/dist/themes/essential.css +36 -0
- package/dist/themes/standard.css +39 -0
- package/package.json +5 -2
|
@@ -48733,6 +48733,11 @@ function formattedQuery(text) {
|
|
|
48733
48733
|
const from = state.doc.resolve(match.from);
|
|
48734
48734
|
const to = state.doc.resolve(match.to);
|
|
48735
48735
|
if (from.parent !== to.parent || !from.parent.inlineContent) return false;
|
|
48736
|
+
if ([
|
|
48737
|
+
"comment_inline",
|
|
48738
|
+
"comment_block",
|
|
48739
|
+
"reference_definition"
|
|
48740
|
+
].includes(from.parent.type.name)) return false;
|
|
48736
48741
|
const content = state.doc.slice(match.from, match.to).content;
|
|
48737
48742
|
let textOnly = true;
|
|
48738
48743
|
content.forEach((node) => {
|
|
@@ -48742,6 +48747,22 @@ function formattedQuery(text) {
|
|
|
48742
48747
|
}
|
|
48743
48748
|
});
|
|
48744
48749
|
}
|
|
48750
|
+
function formattedMatches(state, text) {
|
|
48751
|
+
if (!text) return [];
|
|
48752
|
+
const query = formattedQuery(text);
|
|
48753
|
+
const matches = [];
|
|
48754
|
+
if (!query.valid) return matches;
|
|
48755
|
+
for (let position = 0;;) {
|
|
48756
|
+
const match = query.findNext(state, position);
|
|
48757
|
+
if (!match) break;
|
|
48758
|
+
matches.push({
|
|
48759
|
+
from: match.from,
|
|
48760
|
+
to: match.to
|
|
48761
|
+
});
|
|
48762
|
+
position = match.to;
|
|
48763
|
+
}
|
|
48764
|
+
return matches;
|
|
48765
|
+
}
|
|
48745
48766
|
function findFormatted(view, text) {
|
|
48746
48767
|
const query = formattedQuery(text);
|
|
48747
48768
|
const previous = getSearchState(view.state)?.query.search;
|
|
@@ -48847,6 +48868,33 @@ var EditorSearch = class {
|
|
|
48847
48868
|
restore(match) {
|
|
48848
48869
|
this.literalMatch = match;
|
|
48849
48870
|
}
|
|
48871
|
+
matches(text, snapshotId, projection) {
|
|
48872
|
+
const raw = this.runtime.literal() ? this.runtime.currentText() : void 0;
|
|
48873
|
+
const matches = raw === void 0 ? formattedMatches(this.runtime.view().state, text) : literalMatches(raw, text);
|
|
48874
|
+
let rawPosition = 0, normalizedPosition = 0, spanIndex = 0;
|
|
48875
|
+
const offset = (position) => {
|
|
48876
|
+
if (raw !== void 0) {
|
|
48877
|
+
while (rawPosition < position) {
|
|
48878
|
+
if (raw[rawPosition] !== "\n" || raw[rawPosition - 1] !== "\r") normalizedPosition++;
|
|
48879
|
+
rawPosition++;
|
|
48880
|
+
}
|
|
48881
|
+
return normalizedPosition;
|
|
48882
|
+
}
|
|
48883
|
+
while (spanIndex < projection.spans.length && projection.spans[spanIndex].end < position) spanIndex++;
|
|
48884
|
+
const span = projection.spans[spanIndex];
|
|
48885
|
+
if (!span) return projection.text.length;
|
|
48886
|
+
if (position < span.start) return span.from;
|
|
48887
|
+
return span.kind === "text" ? span.from + Math.max(0, position - span.start) : position === span.start ? span.from : span.to;
|
|
48888
|
+
};
|
|
48889
|
+
return Object.freeze(matches.map((match) => {
|
|
48890
|
+
const start = raw !== void 0 && raw[match.from] === "\n" && raw[match.from - 1] === "\r" ? match.from - 1 : match.from;
|
|
48891
|
+
return Object.freeze({
|
|
48892
|
+
snapshotId,
|
|
48893
|
+
from: offset(start),
|
|
48894
|
+
to: offset(match.to)
|
|
48895
|
+
});
|
|
48896
|
+
}));
|
|
48897
|
+
}
|
|
48850
48898
|
find(text) {
|
|
48851
48899
|
if (this.runtime.literal()) {
|
|
48852
48900
|
const from = this.plainSearch === text ? this.runtime.element().selectionEnd : this.runtime.element().selectionStart;
|
|
@@ -54959,6 +55007,14 @@ function codeControlsPlugin(visibleRect) {
|
|
|
54959
55007
|
button.setAttribute("aria-label", labels.codeLanguage);
|
|
54960
55008
|
button.setAttribute("aria-haspopup", "dialog");
|
|
54961
55009
|
button.setAttribute("aria-expanded", "false");
|
|
55010
|
+
const chevron = document.createElementNS("http://www.w3.org/2000/svg", "svg");
|
|
55011
|
+
chevron.setAttribute("viewBox", "0 0 12 12");
|
|
55012
|
+
chevron.setAttribute("aria-hidden", "true");
|
|
55013
|
+
chevron.setAttribute("focusable", "false");
|
|
55014
|
+
const path = document.createElementNS("http://www.w3.org/2000/svg", "path");
|
|
55015
|
+
path.setAttribute("d", "m3 4.5 3 3 3-3");
|
|
55016
|
+
chevron.append(path);
|
|
55017
|
+
button.append(chevron);
|
|
54962
55018
|
wrapper.append(button);
|
|
54963
55019
|
let popup;
|
|
54964
55020
|
let restore;
|
|
@@ -54971,7 +55027,7 @@ function codeControlsPlugin(visibleRect) {
|
|
|
54971
55027
|
if (focus) button.focus();
|
|
54972
55028
|
};
|
|
54973
55029
|
button.addEventListener("mousedown", (event) => event.preventDefault());
|
|
54974
|
-
button.addEventListener("click", () => {
|
|
55030
|
+
button.addEventListener("click", (event) => {
|
|
54975
55031
|
if (popup) {
|
|
54976
55032
|
close();
|
|
54977
55033
|
return;
|
|
@@ -54979,6 +55035,7 @@ function codeControlsPlugin(visibleRect) {
|
|
|
54979
55035
|
const captured = view.state.doc;
|
|
54980
55036
|
popup = document.createElement("span");
|
|
54981
55037
|
popup.className = "inkkit-code-language-menu";
|
|
55038
|
+
popup.dataset.inkkitInputModality = event.detail === 0 ? "keyboard" : "pointer";
|
|
54982
55039
|
popup.setAttribute("role", "dialog");
|
|
54983
55040
|
popup.setAttribute("aria-label", labels.codeLanguage);
|
|
54984
55041
|
popup.contentEditable = "false";
|
|
@@ -55031,7 +55088,11 @@ function codeControlsPlugin(visibleRect) {
|
|
|
55031
55088
|
}
|
|
55032
55089
|
};
|
|
55033
55090
|
search.addEventListener("input", render);
|
|
55091
|
+
popup.addEventListener("pointerdown", () => {
|
|
55092
|
+
if (popup) popup.dataset.inkkitInputModality = "pointer";
|
|
55093
|
+
});
|
|
55034
55094
|
popup.addEventListener("keydown", (event) => {
|
|
55095
|
+
if (popup && (event.key === "Tab" || event.key.startsWith("Arrow") || event.key === "Home" || event.key === "End" || event.key === "Enter")) popup.dataset.inkkitInputModality = "keyboard";
|
|
55035
55096
|
if (event.key === "Escape") {
|
|
55036
55097
|
event.preventDefault();
|
|
55037
55098
|
event.stopPropagation();
|
|
@@ -55045,7 +55106,8 @@ function codeControlsPlugin(visibleRect) {
|
|
|
55045
55106
|
if (event.key === "ArrowUp") {
|
|
55046
55107
|
event.preventDefault();
|
|
55047
55108
|
const options = [...list.querySelectorAll("button")];
|
|
55048
|
-
options
|
|
55109
|
+
const index = options.indexOf(document.activeElement);
|
|
55110
|
+
options[index < 0 ? options.length - 1 : (index - 1 + options.length) % options.length]?.focus();
|
|
55049
55111
|
}
|
|
55050
55112
|
if (event.key === "Enter" && event.target === search) {
|
|
55051
55113
|
event.preventDefault();
|
|
@@ -57219,7 +57281,7 @@ async function createMilkdownEditor(root, options, runtime) {
|
|
|
57219
57281
|
return true;
|
|
57220
57282
|
}
|
|
57221
57283
|
}));
|
|
57222
|
-
}).use(labelsCtx).use(linkSchemesCtx).use(formatInputCtx).use(richTextGuard).use(runtime.plugins.paste).use(visibleClipboard).use(runtime.plugins.suggestions).use(runtime.plugins.keymap).use(createDialect(Boolean(options.images || options.files), Boolean(options.wikiLinks), Boolean(options.files))).use(codeControlCtx).use(codeControlsPlugin(() => runtime.visibleRect())).use(tablePlugins).use(tableBlock).use(runtime.plugins.change).use(runtime.plugins.historyInput).use(history).use(clipboard).use(cursor).use(taskListPlugin((operation) => runtime.mutate(operation))).use(undoTypedRule).use(quoteBackspace).use(calloutEnter).use(literalEnter).use(literalReread).use(listItemBackspace).use(nestedItemEnter).use(rejoinLists).use(movedListItems).use(textInputPolicy).use(runtime.copy ? codeCopyPlugin((text) => runtime.copy?.(text)) : []).use(placeholderPlugin).use(options.rendering?.codeHighlighting === false ? [] : (await import("./highlight-
|
|
57284
|
+
}).use(labelsCtx).use(linkSchemesCtx).use(formatInputCtx).use(richTextGuard).use(runtime.plugins.paste).use(visibleClipboard).use(runtime.plugins.suggestions).use(runtime.plugins.keymap).use(createDialect(Boolean(options.images || options.files), Boolean(options.wikiLinks), Boolean(options.files))).use(codeControlCtx).use(codeControlsPlugin(() => runtime.visibleRect())).use(tablePlugins).use(tableBlock).use(runtime.plugins.change).use(runtime.plugins.historyInput).use(history).use(clipboard).use(cursor).use(taskListPlugin((operation) => runtime.mutate(operation))).use(undoTypedRule).use(quoteBackspace).use(calloutEnter).use(literalEnter).use(literalReread).use(listItemBackspace).use(nestedItemEnter).use(rejoinLists).use(movedListItems).use(textInputPolicy).use(runtime.copy ? codeCopyPlugin((text) => runtime.copy?.(text)) : []).use(placeholderPlugin).use(options.rendering?.codeHighlighting === false ? [] : (await import("./highlight-C-9lbVMU.js")).highlightPlugin).use(options.rendering?.diagramPreview === false || !diagramsAvailable() ? [] : mermaidPreview(runtime.diagrams, (error) => runtime.report(error))).use(selectionPlugin).use($prose(() => search())).use(runtime.plugins.policy).use(options.wikiLinks ? wikiLinkView(options.wikiLinks, {
|
|
57223
57285
|
capture: () => runtime.capture(),
|
|
57224
57286
|
active: () => runtime.active(),
|
|
57225
57287
|
labels: {
|
|
@@ -60956,6 +61018,14 @@ var InkKitEditor = class InkKitEditor {
|
|
|
60956
61018
|
this.lastMarkdown = markdown;
|
|
60957
61019
|
view.dispatch(initialDocumentSelection(view.state));
|
|
60958
61020
|
}
|
|
61021
|
+
/** Returns every non-overlapping match without changing selection, focus or highlights. */
|
|
61022
|
+
searchMatches(text, expectedGeneration) {
|
|
61023
|
+
this.assertAlive();
|
|
61024
|
+
expectString(text, "text");
|
|
61025
|
+
this.assertCurrent(expectedGeneration);
|
|
61026
|
+
const scope = this.text.scope();
|
|
61027
|
+
return this.search.matches(text, scope.id, scope.projection);
|
|
61028
|
+
}
|
|
60959
61029
|
/** Selects the next match and returns whether there was one. */
|
|
60960
61030
|
find(text, expectedGeneration) {
|
|
60961
61031
|
this.assertAlive();
|
|
@@ -61292,6 +61362,7 @@ var InkKitEditor = class InkKitEditor {
|
|
|
61292
61362
|
"undo",
|
|
61293
61363
|
"redo",
|
|
61294
61364
|
"find",
|
|
61365
|
+
"searchMatches",
|
|
61295
61366
|
"replace",
|
|
61296
61367
|
"replaceAll",
|
|
61297
61368
|
"format",
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { a as Decoration, c as PluginKey, d as __toESM, i as $prose, o as DecorationSet, s as Plugin, u as __commonJSMin } from "./core-
|
|
1
|
+
import { a as Decoration, c as PluginKey, d as __toESM, i as $prose, o as DecorationSet, s as Plugin, u as __commonJSMin } from "./core-CbHV2KPY.js";
|
|
2
2
|
//#region node_modules/.pnpm/highlight.js@11.11.2/node_modules/highlight.js/es/languages/arduino.js
|
|
3
3
|
/** @type LanguageFn */
|
|
4
4
|
function cPlusPlus(hljs) {
|
package/dist/core.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { r as InkKitError, t as InkKitEditor } from "./chunks/core-
|
|
1
|
+
import { r as InkKitError, t as InkKitEditor } from "./chunks/core-CbHV2KPY.js";
|
|
2
2
|
export { InkKitEditor, InkKitError };
|
package/dist/editor.d.ts
CHANGED
|
@@ -371,6 +371,8 @@ export declare class InkKitEditor<F extends DocumentFormat = TextDocumentFormat>
|
|
|
371
371
|
private revealCurrentSelection;
|
|
372
372
|
private revealLiteralSelection;
|
|
373
373
|
private load;
|
|
374
|
+
/** Returns every non-overlapping match without changing selection, focus or highlights. */
|
|
375
|
+
searchMatches(text: string, expectedGeneration?: number): readonly TextRange[];
|
|
374
376
|
/** Selects the next match and returns whether there was one. */
|
|
375
377
|
find(text: string, expectedGeneration?: number): boolean;
|
|
376
378
|
/** Replaces the selected match, or the next one, and returns whether text changed. */
|
package/dist/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { n as registerDiagram, r as InkKitError, t as InkKitEditor } from "./chunks/core-
|
|
1
|
+
import { n as registerDiagram, r as InkKitError, t as InkKitEditor } from "./chunks/core-CbHV2KPY.js";
|
|
2
2
|
//#region node_modules/.pnpm/dompurify@3.4.17/node_modules/dompurify/dist/purify.es.mjs
|
|
3
3
|
/*! @license DOMPurify 3.4.17 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/3.4.17/LICENSE */
|
|
4
4
|
function _OverloadYield(e, d) {
|
package/dist/style.css
CHANGED
|
@@ -3,6 +3,7 @@
|
|
|
3
3
|
box-sizing: border-box;
|
|
4
4
|
color-scheme: var(--inkkit-color-scheme, light dark);
|
|
5
5
|
color: var(--inkkit-text-color, CanvasText);
|
|
6
|
+
background: var(--inkkit-background-color, transparent);
|
|
6
7
|
font-family: var(
|
|
7
8
|
--inkkit-font-family,
|
|
8
9
|
-apple-system,
|
|
@@ -628,7 +629,7 @@
|
|
|
628
629
|
font-size: calc(var(--_inkkit-font-size) * 0.867);
|
|
629
630
|
line-height: 1.5;
|
|
630
631
|
background: var(--_inkkit-code-bg);
|
|
631
|
-
border-radius: 8px;
|
|
632
|
+
border-radius: var(--inkkit-code-radius, 8px);
|
|
632
633
|
padding: calc(var(--_inkkit-font-size) * 0.8)
|
|
633
634
|
calc(var(--_inkkit-font-size) * 0.933);
|
|
634
635
|
margin: 0 0 calc(var(--_inkkit-font-size) * 0.8);
|
|
@@ -679,9 +680,27 @@
|
|
|
679
680
|
}
|
|
680
681
|
|
|
681
682
|
.inkkit-root .ProseMirror blockquote {
|
|
683
|
+
position: relative;
|
|
682
684
|
margin: 0 0 calc(var(--_inkkit-font-size) * 0.8);
|
|
683
|
-
padding: 2px 0 2px
|
|
684
|
-
|
|
685
|
+
padding: 2px 0 2px
|
|
686
|
+
calc(var(--_inkkit-font-size) * 0.8 + var(--inkkit-quote-rule-width, 2px));
|
|
687
|
+
}
|
|
688
|
+
|
|
689
|
+
.inkkit-root .ProseMirror blockquote::before {
|
|
690
|
+
content: '';
|
|
691
|
+
position: absolute;
|
|
692
|
+
inset: 0 auto 0 0;
|
|
693
|
+
width: var(--inkkit-quote-rule-width, 2px);
|
|
694
|
+
border-radius: var(--inkkit-quote-rule-radius, 0px);
|
|
695
|
+
background: var(--inkkit-quote-rule-color, var(--_inkkit-accent));
|
|
696
|
+
pointer-events: none;
|
|
697
|
+
}
|
|
698
|
+
|
|
699
|
+
@media (forced-colors: active) {
|
|
700
|
+
.inkkit-root .ProseMirror blockquote::before {
|
|
701
|
+
background: CanvasText;
|
|
702
|
+
forced-color-adjust: none;
|
|
703
|
+
}
|
|
685
704
|
}
|
|
686
705
|
|
|
687
706
|
.inkkit-root .ProseMirror blockquote > :first-child {
|
|
@@ -1211,6 +1230,9 @@
|
|
|
1211
1230
|
user-select: none;
|
|
1212
1231
|
}
|
|
1213
1232
|
.inkkit-root .inkkit-code-language {
|
|
1233
|
+
display: inline-flex;
|
|
1234
|
+
align-items: center;
|
|
1235
|
+
gap: 5px;
|
|
1214
1236
|
height: 24px;
|
|
1215
1237
|
padding: 0 6px;
|
|
1216
1238
|
border: 0;
|
|
@@ -1220,9 +1242,15 @@
|
|
|
1220
1242
|
font: inherit;
|
|
1221
1243
|
cursor: pointer;
|
|
1222
1244
|
}
|
|
1223
|
-
.inkkit-root .inkkit-code-language
|
|
1224
|
-
|
|
1225
|
-
|
|
1245
|
+
.inkkit-root .inkkit-code-language svg {
|
|
1246
|
+
flex-shrink: 0;
|
|
1247
|
+
width: 12px;
|
|
1248
|
+
height: 12px;
|
|
1249
|
+
fill: none;
|
|
1250
|
+
stroke: currentColor;
|
|
1251
|
+
stroke-width: 1.25;
|
|
1252
|
+
stroke-linecap: round;
|
|
1253
|
+
stroke-linejoin: round;
|
|
1226
1254
|
}
|
|
1227
1255
|
.inkkit-root .inkkit-code-language:hover {
|
|
1228
1256
|
background: color-mix(in srgb, CanvasText 7%, transparent);
|
|
@@ -1240,7 +1268,7 @@
|
|
|
1240
1268
|
flex-direction: column;
|
|
1241
1269
|
width: 220px;
|
|
1242
1270
|
max-height: min(320px, 50vh);
|
|
1243
|
-
padding:
|
|
1271
|
+
padding: 6px;
|
|
1244
1272
|
box-sizing: border-box;
|
|
1245
1273
|
border: 1px solid color-mix(in srgb, CanvasText 15%, transparent);
|
|
1246
1274
|
border-radius: 8px;
|
|
@@ -1252,10 +1280,10 @@
|
|
|
1252
1280
|
box-sizing: border-box;
|
|
1253
1281
|
min-width: 0;
|
|
1254
1282
|
width: 100%;
|
|
1255
|
-
padding: 7px;
|
|
1256
|
-
border:
|
|
1257
|
-
border-
|
|
1258
|
-
background: transparent;
|
|
1283
|
+
padding: 7px 8px;
|
|
1284
|
+
border: 1px solid color-mix(in srgb, CanvasText 12%, transparent);
|
|
1285
|
+
border-radius: 5px;
|
|
1286
|
+
background: color-mix(in srgb, CanvasText 3%, transparent);
|
|
1259
1287
|
color: inherit;
|
|
1260
1288
|
font: inherit;
|
|
1261
1289
|
}
|
|
@@ -1263,7 +1291,7 @@
|
|
|
1263
1291
|
display: flex;
|
|
1264
1292
|
flex-direction: column;
|
|
1265
1293
|
overflow-y: auto;
|
|
1266
|
-
padding
|
|
1294
|
+
padding: 4px 0 0;
|
|
1267
1295
|
}
|
|
1268
1296
|
.inkkit-root .inkkit-code-language-list button {
|
|
1269
1297
|
flex-shrink: 0;
|
|
@@ -1277,10 +1305,40 @@
|
|
|
1277
1305
|
cursor: pointer;
|
|
1278
1306
|
}
|
|
1279
1307
|
.inkkit-root .inkkit-code-language-list button:hover,
|
|
1280
|
-
.inkkit-root
|
|
1308
|
+
.inkkit-root
|
|
1309
|
+
.inkkit-code-language-menu[data-inkkit-input-modality='keyboard']
|
|
1310
|
+
.inkkit-code-language-list
|
|
1311
|
+
button:focus,
|
|
1281
1312
|
.inkkit-root .inkkit-code-language-list button[aria-pressed='true'] {
|
|
1282
1313
|
background: color-mix(in srgb, CanvasText 8%, transparent);
|
|
1283
1314
|
}
|
|
1315
|
+
.inkkit-root .inkkit-code-language-menu input:focus,
|
|
1316
|
+
.inkkit-root .inkkit-code-language-menu button:focus {
|
|
1317
|
+
outline: none;
|
|
1318
|
+
}
|
|
1319
|
+
.inkkit-root
|
|
1320
|
+
.inkkit-code-language-menu[data-inkkit-input-modality='keyboard']
|
|
1321
|
+
input:focus,
|
|
1322
|
+
.inkkit-root
|
|
1323
|
+
.inkkit-code-language-menu[data-inkkit-input-modality='keyboard']
|
|
1324
|
+
button:focus {
|
|
1325
|
+
outline: var(--inkkit-focus-width, 2px) solid
|
|
1326
|
+
var(--inkkit-focus-color, var(--_inkkit-accent));
|
|
1327
|
+
outline-offset: var(--inkkit-focus-offset, -2px);
|
|
1328
|
+
}
|
|
1329
|
+
@media (forced-colors: active) {
|
|
1330
|
+
.inkkit-root .inkkit-code-language-menu input {
|
|
1331
|
+
border-color: ButtonBorder;
|
|
1332
|
+
}
|
|
1333
|
+
.inkkit-root
|
|
1334
|
+
.inkkit-code-language-menu[data-inkkit-input-modality='keyboard']
|
|
1335
|
+
input:focus,
|
|
1336
|
+
.inkkit-root
|
|
1337
|
+
.inkkit-code-language-menu[data-inkkit-input-modality='keyboard']
|
|
1338
|
+
button:focus {
|
|
1339
|
+
outline-color: Highlight;
|
|
1340
|
+
}
|
|
1341
|
+
}
|
|
1284
1342
|
|
|
1285
1343
|
.inkkit-root .milkdown-drop-indicator {
|
|
1286
1344
|
background: var(--inkkit-drop-indicator-color, var(--_inkkit-accent));
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
:where([data-inkkit-theme='calm']) {
|
|
2
|
+
--inkkit-font-family:
|
|
3
|
+
-apple-system, BlinkMacSystemFont, system-ui, sans-serif;
|
|
4
|
+
--inkkit-font-size: 15px;
|
|
5
|
+
--inkkit-paragraph-spacing: calc(var(--inkkit-font-size) * 0.667);
|
|
6
|
+
--inkkit-reading-width: 100%;
|
|
7
|
+
--inkkit-background-color: light-dark(#ffffff, #1d2430);
|
|
8
|
+
--inkkit-text-color: light-dark(#252c36, #e6eaf0);
|
|
9
|
+
--inkkit-muted-color: light-dark(#656f7c, #a4adbb);
|
|
10
|
+
--inkkit-accent-color: light-dark(#3064af, #9abbf5);
|
|
11
|
+
--inkkit-rule-color: light-dark(#dce2e9, #434d5e);
|
|
12
|
+
--inkkit-checkbox-border-color: var(--inkkit-muted-color);
|
|
13
|
+
--inkkit-code-background: light-dark(#f3f5f8, #272e3a);
|
|
14
|
+
--inkkit-table-radius: 8px;
|
|
15
|
+
--inkkit-code-radius: 8px;
|
|
16
|
+
--inkkit-quote-rule-width: 3px;
|
|
17
|
+
--inkkit-quote-rule-radius: 2px;
|
|
18
|
+
--inkkit-quote-rule-color: light-dark(#a6a6a6, #777777);
|
|
19
|
+
--inkkit-code-comment: light-dark(#6e6e6e, #99999a);
|
|
20
|
+
--inkkit-code-keyword: light-dark(#a626a4, #c77bde);
|
|
21
|
+
--inkkit-code-string: light-dark(#3b763a, #98c379);
|
|
22
|
+
--inkkit-code-number: light-dark(#8d6001, #d19a66);
|
|
23
|
+
--inkkit-code-title: light-dark(#8d6101, #e5c07b);
|
|
24
|
+
--inkkit-code-attr: light-dark(#c82c1e, #e37981);
|
|
25
|
+
--inkkit-diagram-background: light-dark(#ffffff, #1d2430);
|
|
26
|
+
--inkkit-diagram-text-color: light-dark(#252c36, #e6eaf0);
|
|
27
|
+
--inkkit-diagram-color-strength: 35%;
|
|
28
|
+
--inkkit-diagram-series-1: light-dark(#4d87d5, #9abbf5);
|
|
29
|
+
--inkkit-diagram-series-2: light-dark(#69ad91, #a1d6bd);
|
|
30
|
+
--inkkit-diagram-series-3: light-dark(#9b80ce, #c4aff0);
|
|
31
|
+
--inkkit-diagram-series-4: light-dark(#d6a660, #edce9b);
|
|
32
|
+
--inkkit-diagram-series-5: light-dark(#ce819a, #eeb4c8);
|
|
33
|
+
--inkkit-diagram-series-6: light-dark(#65b4b1, #9edbd7);
|
|
34
|
+
--inkkit-diagram-series-7: light-dark(#cab85d, #e9dd99);
|
|
35
|
+
--inkkit-diagram-series-8: light-dark(#7ca9c5, #b1d6ed);
|
|
36
|
+
}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
:where([data-inkkit-theme='essential']) {
|
|
2
|
+
--inkkit-font-family:
|
|
3
|
+
-apple-system, BlinkMacSystemFont, system-ui, sans-serif;
|
|
4
|
+
--inkkit-font-size: 15px;
|
|
5
|
+
--inkkit-paragraph-spacing: calc(var(--inkkit-font-size) * 0.667);
|
|
6
|
+
--inkkit-reading-width: 100%;
|
|
7
|
+
--inkkit-background-color: light-dark(#ffffff, #1c1c1c);
|
|
8
|
+
--inkkit-text-color: light-dark(#262626, #e8e8e8);
|
|
9
|
+
--inkkit-muted-color: light-dark(#707070, #a6a6a6);
|
|
10
|
+
--inkkit-accent-color: light-dark(#555555, #c4c4c4);
|
|
11
|
+
--inkkit-rule-color: light-dark(#dddddd, #444444);
|
|
12
|
+
--inkkit-checkbox-border-color: var(--inkkit-muted-color);
|
|
13
|
+
--inkkit-code-background: light-dark(#f7f7f7, #2a2a2a);
|
|
14
|
+
--inkkit-table-radius: 4px;
|
|
15
|
+
--inkkit-code-radius: 4px;
|
|
16
|
+
--inkkit-quote-rule-width: 3px;
|
|
17
|
+
--inkkit-quote-rule-radius: 2px;
|
|
18
|
+
--inkkit-quote-rule-color: light-dark(#a6a6a6, #777777);
|
|
19
|
+
--inkkit-code-comment: light-dark(#707070, #929292);
|
|
20
|
+
--inkkit-code-keyword: light-dark(#333333, #eeeeee);
|
|
21
|
+
--inkkit-code-string: light-dark(#686868, #bbbbbb);
|
|
22
|
+
--inkkit-code-number: light-dark(#555555, #c8c8c8);
|
|
23
|
+
--inkkit-code-title: light-dark(#444444, #dddddd);
|
|
24
|
+
--inkkit-code-attr: light-dark(#707070, #aaaaaa);
|
|
25
|
+
--inkkit-diagram-background: light-dark(#ffffff, #1c1c1c);
|
|
26
|
+
--inkkit-diagram-text-color: light-dark(#262626, #e8e8e8);
|
|
27
|
+
--inkkit-diagram-color-strength: 75%;
|
|
28
|
+
--inkkit-diagram-series-1: light-dark(#3d3d3d, #eeeeee);
|
|
29
|
+
--inkkit-diagram-series-2: light-dark(#5a5a5a, #d6d6d6);
|
|
30
|
+
--inkkit-diagram-series-3: light-dark(#747474, #bebebe);
|
|
31
|
+
--inkkit-diagram-series-4: light-dark(#8b8b8b, #a6a6a6);
|
|
32
|
+
--inkkit-diagram-series-5: light-dark(#a0a0a0, #8e8e8e);
|
|
33
|
+
--inkkit-diagram-series-6: light-dark(#b4b4b4, #767676);
|
|
34
|
+
--inkkit-diagram-series-7: light-dark(#c6c6c6, #5e5e5e);
|
|
35
|
+
--inkkit-diagram-series-8: light-dark(#d7d7d7, #464646);
|
|
36
|
+
}
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
:where([data-inkkit-theme='standard']) {
|
|
2
|
+
--inkkit-font-family:
|
|
3
|
+
-apple-system, BlinkMacSystemFont, system-ui, sans-serif;
|
|
4
|
+
--inkkit-font-size: 15px;
|
|
5
|
+
--inkkit-paragraph-spacing: calc(var(--inkkit-font-size) * 0.667);
|
|
6
|
+
--inkkit-reading-width: 100%;
|
|
7
|
+
--inkkit-background-color: light-dark(#ffffff, #1c1c1e);
|
|
8
|
+
--inkkit-text-color: CanvasText;
|
|
9
|
+
--inkkit-muted-color: light-dark(#6e6e6e, #99999a);
|
|
10
|
+
--inkkit-accent-color: light-dark(#0069d1, #409cff);
|
|
11
|
+
--inkkit-rule-color: color-mix(in srgb, CanvasText 14%, transparent);
|
|
12
|
+
--inkkit-checkbox-border-color: var(--inkkit-muted-color);
|
|
13
|
+
--inkkit-code-background: light-dark(
|
|
14
|
+
#f3f5f8,
|
|
15
|
+
color-mix(in srgb, CanvasText 8%, transparent)
|
|
16
|
+
);
|
|
17
|
+
--inkkit-table-radius: 8px;
|
|
18
|
+
--inkkit-code-radius: 8px;
|
|
19
|
+
--inkkit-quote-rule-width: 3px;
|
|
20
|
+
--inkkit-quote-rule-radius: 2px;
|
|
21
|
+
--inkkit-quote-rule-color: light-dark(#a6a6a6, #777777);
|
|
22
|
+
--inkkit-code-comment: light-dark(#6e6e6e, #99999a);
|
|
23
|
+
--inkkit-code-keyword: light-dark(#a626a4, #c77bde);
|
|
24
|
+
--inkkit-code-string: light-dark(#3b763a, #98c379);
|
|
25
|
+
--inkkit-code-number: light-dark(#8d6001, #d19a66);
|
|
26
|
+
--inkkit-code-title: light-dark(#8d6101, #e5c07b);
|
|
27
|
+
--inkkit-code-attr: light-dark(#c82c1e, #e37981);
|
|
28
|
+
--inkkit-diagram-background: light-dark(#ffffff, #1c1c1e);
|
|
29
|
+
--inkkit-diagram-text-color: light-dark(#1c1c1e, #f2f2f7);
|
|
30
|
+
--inkkit-diagram-color-strength: 35%;
|
|
31
|
+
--inkkit-diagram-series-1: light-dark(#0088ff, #0091ff);
|
|
32
|
+
--inkkit-diagram-series-2: light-dark(#34c759, #30d158);
|
|
33
|
+
--inkkit-diagram-series-3: light-dark(#6155f5, #6d7cff);
|
|
34
|
+
--inkkit-diagram-series-4: light-dark(#ff8d28, #ff9230);
|
|
35
|
+
--inkkit-diagram-series-5: light-dark(#ff383c, #ff4245);
|
|
36
|
+
--inkkit-diagram-series-6: light-dark(#00c8b3, #00dac3);
|
|
37
|
+
--inkkit-diagram-series-7: light-dark(#ffcc00, #ffd600);
|
|
38
|
+
--inkkit-diagram-series-8: light-dark(#00c0e8, #3cd3fe);
|
|
39
|
+
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@aicayzer/inkkit",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.6.1",
|
|
4
4
|
"description": "A preserving Markdown editor for offline web views and the web",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "module",
|
|
@@ -17,7 +17,10 @@
|
|
|
17
17
|
"types": "./dist/core.d.ts",
|
|
18
18
|
"import": "./dist/core.js"
|
|
19
19
|
},
|
|
20
|
-
"./style.css": "./dist/style.css"
|
|
20
|
+
"./style.css": "./dist/style.css",
|
|
21
|
+
"./themes/standard.css": "./dist/themes/standard.css",
|
|
22
|
+
"./themes/calm.css": "./dist/themes/calm.css",
|
|
23
|
+
"./themes/essential.css": "./dist/themes/essential.css"
|
|
21
24
|
},
|
|
22
25
|
"types": "./dist/index.d.ts",
|
|
23
26
|
"files": [
|