@withmarfa/inkkit 0.0.0-stage → 0.8.0-alpha.0

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/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 August Cayzer
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/NOTICE ADDED
@@ -0,0 +1,41 @@
1
+ The scoped table styles in src/style.css are adapted from prosemirror-tables.
2
+ Source: https://github.com/ProseMirror/prosemirror-tables
3
+
4
+ Copyright (C) 2015-2016 by Marijn Haverbeke <marijnh@gmail.com> and others
5
+
6
+ Permission is hereby granted, free of charge, to any person obtaining a copy
7
+ of this software and associated documentation files (the "Software"), to deal
8
+ in the Software without restriction, including without limitation the rights
9
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
10
+ copies of the Software, and to permit persons to whom the Software is
11
+ furnished to do so, subject to the following conditions:
12
+
13
+ The above copyright notice and this permission notice shall be included in
14
+ all copies or substantial portions of the Software.
15
+
16
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
17
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
18
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
19
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
20
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
21
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
22
+ THE SOFTWARE.
23
+
24
+ The published package bundles Milkdown, ProseMirror and other packages. Each
25
+ keeps its own license. dist/THIRD-PARTY-NOTICES.txt lists their versions,
26
+ licenses and notice texts for both entries, including the core entry.
27
+
28
+ The main entry bundles Pele and DOMPurify. The generated third-party
29
+ notices include Pele's complete license file and its Lucide ISC notice.
30
+ dist/THIRD-PARTY-NOTICES-FULL.txt contains the same notices and remains
31
+ available for existing host build recipes. The core entry includes neither
32
+ Pele nor DOMPurify.
33
+
34
+ When distributing an inlined page, carry Inkkit's LICENSE, this NOTICE and
35
+ dist/THIRD-PARTY-NOTICES.txt alongside the page. Also generate notices from
36
+ the host's bundle for any other host dependencies. Making one HTML file
37
+ does not remove the dependencies' license requirements.
38
+ Review the license terms, including any applicable source obligations;
39
+ a list of notices alone does not establish compliance.
40
+
41
+ Build recipe: https://inkkit.withmarfa.com/guides/web-view#carry-the-license-notices
package/README.md CHANGED
@@ -1,3 +1,48 @@
1
- # Temporary Holding Version
1
+ # Inkkit
2
2
 
3
- This version is a temporary placeholder for this package. An operational version to replace this has been submitted for review and is awaiting a staged release.
3
+ A Markdown editor for web pages and for apps that host a web view. People edit formatted text, and your app saves the Markdown as it was written: an unedited document is saved unchanged, and an edit rewrites only the blocks it touches.
4
+
5
+ <details>
6
+ <summary>How Inkkit preserves Markdown</summary>
7
+
8
+ <picture>
9
+ <source media="(prefers-color-scheme: dark)" srcset="docs/images/how-inkkit-works-dark.svg">
10
+ <img src="docs/images/how-inkkit-works.svg" alt="Inkkit keeps unchanged source and checks edited blocks before your app saves them.">
11
+ </picture>
12
+
13
+ </details>
14
+
15
+ ## Get started
16
+
17
+ ```sh
18
+ npm install @withmarfa/inkkit
19
+ ```
20
+
21
+ ```ts
22
+ import { InkKitEditor } from '@withmarfa/inkkit'
23
+ import '@withmarfa/inkkit/style.css'
24
+
25
+ const editor = await InkKitEditor.mount(document.getElementById('editor')!, {
26
+ changed() {},
27
+ error(error) {
28
+ console.error(error.code, error.message)
29
+ },
30
+ })
31
+
32
+ editor.loadDocument({
33
+ documentId: 'note',
34
+ generation: 1,
35
+ format: 'md',
36
+ text: '# Hello\n\nStart writing.\n',
37
+ })
38
+
39
+ const { text } = editor.snapshot(1)
40
+ ```
41
+
42
+ ## Documentation
43
+
44
+ [inkkit.withmarfa.com](https://inkkit.withmarfa.com) covers how Inkkit works, compatibility, integration guides and the API reference.
45
+
46
+ ## License
47
+
48
+ [MIT](LICENSE). Third-party notices are in [NOTICE](NOTICE).