Commit Graph

125 Commits

Author SHA1 Message Date
Arnau Gómez Farell
2bd5b987eb
fix: apply prettier and eslint automatic fixes 2025-05-20 15:01:15 +02:00
bdbch
5988305f34
make sure rel attribute is set on html output for YouTube extension (#6280) 2025-04-18 16:32:44 +02:00
Dominik Biedebach
46d9ee4987 fix table tests 2025-03-27 22:45:34 +01:00
bdbch
d8a3d93c8a
Rename History extension to UndoRedo (#6172)
* rename history extension to undo-redo

* added changesets

* fix spacing in vue demo
2025-03-12 14:55:16 +01:00
Arnau Gómez Farell
89bd9c7d29
Fix/enforce-type-imports-so-that-bundler-ignores-types (#6132)
* fix: enforce type imports so that the bundler ignores types

* chore: add changeset

* fix: export types with export type keyword
2025-03-03 15:15:30 +01:00
Nick Perez
32958d6fa7
feat(core): editor.storage strong typing and separate instances (#6060) 2025-01-28 16:52:10 +01:00
Nick Perez
a0e0dc7597
feat: update changesets and move more extensions into @tiptap/extensions (#6056) 2025-01-27 14:42:45 +01:00
Nick Perez
dd0a25f5b4
feat(core): add JSX transformer for DX of renderHTML method (#5558)
Some checks are pending
build / build (20) (push) Waiting to run
build / test (20, map[name:Demos/Commands spec:./demos/src/Commands/**/*.spec.{js,ts}]) (push) Blocked by required conditions
build / test (20, map[name:Demos/Examples spec:./demos/src/Examples/**/*.spec.{js,ts}]) (push) Blocked by required conditions
build / test (20, map[name:Demos/Experiments spec:./demos/src/Experiments/**/*.spec.{js,ts}]) (push) Blocked by required conditions
build / test (20, map[name:Demos/Extensions spec:./demos/src/Extensions/**/*.spec.{js,ts}]) (push) Blocked by required conditions
build / test (20, map[name:Demos/GuideContent spec:./demos/src/GuideContent/**/*.spec.{js,ts}]) (push) Blocked by required conditions
build / test (20, map[name:Demos/GuideGettingStarted spec:./demos/src/GuideGettingStarted/**/*.spec.{js,ts}]) (push) Blocked by required conditions
build / test (20, map[name:Demos/Marks spec:./demos/src/Marks/**/*.spec.{js,ts}]) (push) Blocked by required conditions
build / test (20, map[name:Demos/Nodes spec:./demos/src/Nodes/**/*.spec.{js,ts}]) (push) Blocked by required conditions
build / test (20, map[name:Integration spec:./tests/cypress/integration/**/*.spec.{js,ts}]) (push) Blocked by required conditions
build / release (20) (push) Blocked by required conditions
Publish / Release (20) (push) Waiting to run
2025-01-22 10:24:38 +01:00
Nick Perez
4c995e4c63
test: add tests specifically for React static rendering (#6029)
Some checks failed
build / build (20) (push) Has been cancelled
Publish / Release (20) (push) Has been cancelled
build / test (20, map[name:Demos/Commands spec:./demos/src/Commands/**/*.spec.{js,ts}]) (push) Has been cancelled
build / test (20, map[name:Demos/Examples spec:./demos/src/Examples/**/*.spec.{js,ts}]) (push) Has been cancelled
build / test (20, map[name:Demos/Experiments spec:./demos/src/Experiments/**/*.spec.{js,ts}]) (push) Has been cancelled
build / test (20, map[name:Demos/Extensions spec:./demos/src/Extensions/**/*.spec.{js,ts}]) (push) Has been cancelled
build / test (20, map[name:Demos/GuideContent spec:./demos/src/GuideContent/**/*.spec.{js,ts}]) (push) Has been cancelled
build / test (20, map[name:Demos/GuideGettingStarted spec:./demos/src/GuideGettingStarted/**/*.spec.{js,ts}]) (push) Has been cancelled
build / test (20, map[name:Demos/Marks spec:./demos/src/Marks/**/*.spec.{js,ts}]) (push) Has been cancelled
build / test (20, map[name:Demos/Nodes spec:./demos/src/Nodes/**/*.spec.{js,ts}]) (push) Has been cancelled
build / test (20, map[name:Integration spec:./tests/cypress/integration/**/*.spec.{js,ts}]) (push) Has been cancelled
build / release (20) (push) Has been cancelled
2025-01-17 11:21:09 +01:00
Nick Perez
bf040b9044
feat(html): switch from zeed-dom to happy-dom-without-node (#5984)
Some checks are pending
build / build (20) (push) Waiting to run
build / test (20, map[name:Demos/Commands spec:./demos/src/Commands/**/*.spec.{js,ts}]) (push) Blocked by required conditions
build / test (20, map[name:Demos/Examples spec:./demos/src/Examples/**/*.spec.{js,ts}]) (push) Blocked by required conditions
build / test (20, map[name:Demos/Experiments spec:./demos/src/Experiments/**/*.spec.{js,ts}]) (push) Blocked by required conditions
build / test (20, map[name:Demos/Extensions spec:./demos/src/Extensions/**/*.spec.{js,ts}]) (push) Blocked by required conditions
build / test (20, map[name:Demos/GuideContent spec:./demos/src/GuideContent/**/*.spec.{js,ts}]) (push) Blocked by required conditions
build / test (20, map[name:Demos/GuideGettingStarted spec:./demos/src/GuideGettingStarted/**/*.spec.{js,ts}]) (push) Blocked by required conditions
build / test (20, map[name:Demos/Marks spec:./demos/src/Marks/**/*.spec.{js,ts}]) (push) Blocked by required conditions
build / test (20, map[name:Demos/Nodes spec:./demos/src/Nodes/**/*.spec.{js,ts}]) (push) Blocked by required conditions
build / test (20, map[name:Integration spec:./tests/cypress/integration/**/*.spec.{js,ts}]) (push) Blocked by required conditions
build / release (20) (push) Blocked by required conditions
Publish / Release (20) (push) Waiting to run
2025-01-08 09:45:39 +01:00
Nick Perez
0b4981c832
feat(text-style): merge all pkgs into text-style, add background-color and line-height (#6001) 2025-01-08 08:03:52 +01:00
Nick Perez
6a53bb2699
feat(static-renderer): add @tiptap/static-renderer to enable static rendering of content (#5528)
Some checks failed
build / build (20) (push) Has been cancelled
Publish / Release (20) (push) Has been cancelled
build / test (20, map[name:Demos/Commands spec:./demos/src/Commands/**/*.spec.{js,ts}]) (push) Has been cancelled
build / test (20, map[name:Demos/Examples spec:./demos/src/Examples/**/*.spec.{js,ts}]) (push) Has been cancelled
build / test (20, map[name:Demos/Experiments spec:./demos/src/Experiments/**/*.spec.{js,ts}]) (push) Has been cancelled
build / test (20, map[name:Demos/Extensions spec:./demos/src/Extensions/**/*.spec.{js,ts}]) (push) Has been cancelled
build / test (20, map[name:Demos/GuideContent spec:./demos/src/GuideContent/**/*.spec.{js,ts}]) (push) Has been cancelled
build / test (20, map[name:Demos/GuideGettingStarted spec:./demos/src/GuideGettingStarted/**/*.spec.{js,ts}]) (push) Has been cancelled
build / test (20, map[name:Demos/Marks spec:./demos/src/Marks/**/*.spec.{js,ts}]) (push) Has been cancelled
build / test (20, map[name:Demos/Nodes spec:./demos/src/Nodes/**/*.spec.{js,ts}]) (push) Has been cancelled
build / test (20, map[name:Integration spec:./tests/cypress/integration/**/*.spec.{js,ts}]) (push) Has been cancelled
build / release (20) (push) Has been cancelled
2025-01-06 14:00:38 +01:00
Nick Perez
7b4e6f5d11
build: migrate to pnpm (#5978) 2025-01-06 09:35:00 +01:00
Nick the Sick
43a8cedd5b
Merge branch 'develop' into next 2024-12-31 11:18:19 +01:00
Dominik Biedebach
4b1b423021 remove unused test 2024-11-30 16:32:08 +01:00
bdbch
d9b6ef5ce2
fix emptyTextBlock detection to handle leaf nodes too (#5838)
* fix: #4327

* merge forked PR

---------

Co-authored-by: Tony Hallett <tonyhallett74@gmail.com>
2024-11-30 14:19:16 +01:00
Nick Perez
2ea807d1db
fix(core): getMarkRange match only the current mark of a type #3872 (#5826)
Some checks failed
build / lint (20) (push) Has been cancelled
build / test (20, map[name:Demos/Examples spec:./demos/src/Examples/**/*.spec.{js,ts}]) (push) Has been cancelled
build / test (20, map[name:Demos/Experiments spec:./demos/src/Experiments/**/*.spec.{js,ts}]) (push) Has been cancelled
build / test (20, map[name:Demos/Extensions spec:./demos/src/Extensions/**/*.spec.{js,ts}]) (push) Has been cancelled
build / test (20, map[name:Demos/GuideContent spec:./demos/src/GuideContent/**/*.spec.{js,ts}]) (push) Has been cancelled
build / test (20, map[name:Demos/GuideGettingStarted spec:./demos/src/GuideGettingStarted/**/*.spec.{js,ts}]) (push) Has been cancelled
build / test (20, map[name:Demos/Marks spec:./demos/src/Marks/**/*.spec.{js,ts}]) (push) Has been cancelled
build / test (20, map[name:Demos/Nodes spec:./demos/src/Nodes/**/*.spec.{js,ts}]) (push) Has been cancelled
build / test (20, map[name:Integration spec:./tests/cypress/integration/**/*.spec.{js,ts}]) (push) Has been cancelled
Publish / Release (20) (push) Has been cancelled
build / build (20) (push) Has been cancelled
2024-11-17 18:35:59 +01:00
Nick Perez
873a67c6e3
feat: in a collab setting, disable transactions that are trying to sync invalid content (#5207)
When collaborating on a document, a client may send changes which are invalid to the current client. This change makes it so that the client can be disabled from synchronizing any further changes to avoid the default behavior of stripping unknown content. This would allow the other client to continue editing on the document while still synchronizing any known changes.
2024-10-21 17:15:06 +02:00
bdbch
4efd2278a1
Fix getMarkRange not finding marks when at the start of a mark (#5717)
* fix getMarkRange to always find a mark, even if cursor is at start of mark

* added changesets

* added integration tests for getMarkRange

* remove console.logs

* added forward and backward boundary checks for tests
2024-10-11 06:44:05 +02:00
Jaap van Hoek
21df331b60
fix(table): respect resizeable columns colwidths (#4955) 2024-10-04 14:17:08 +02:00
Nick Perez
6834a7f7d6
build: type defs only emit for a single package's code (#5665) 2024-09-26 14:51:00 +02:00
Nick the Sick
e0c4db9674
revert: "fix(core): handle macOS text expansion properly in InputRules (#5261)"
This reverts commit 88e310b144.
2024-09-16 06:19:37 +02:00
Ricardo Amaral
88e310b144
fix(core): handle macOS text expansion properly in InputRules (#5261) 2024-08-22 12:34:27 +02:00
Leopold Pinkernell
f805333f63
fix(core): check schema's nesting rules on contentCheck (#5500) (#5535) 2024-08-21 22:44:17 +02:00
sifat haque
a22767e9e1
fix(core): styles de-duplicate in mergeAttributes (#4610) 2024-08-21 22:39:58 +02:00
Nick Perez
593f1070a8
fix(link): respect custom protocols #5468 (#5470)
When [we fixed a XSS vuln](https://github.com/ueberdosis/tiptap/pull/5160), we inadvertently broke the ability to use custom protocols, this resolves that by allowing additional custom protocols to be considered valid and not stripped out
2024-08-15 08:57:59 +02:00
Nick Perez
d6e56c41e3
fix(extension-code-block-lowlight): use lowlight v3 and update demos (#5374) 2024-08-06 13:53:58 +02:00
Nick Perez
ae0254db97
feat(core): add ignoreWhitespace option to isNodeEmpty (#5446) 2024-08-06 10:05:50 +02:00
Nick Perez
84ebd511d2
fix(core): resolve isNodeEmpty criteria #5415 (#5419) 2024-08-01 09:02:34 +02:00
Nick Perez
b012471755
fix(core): isNodeEmpty no longer considers attributes for it's checks (#5393) 2024-07-25 15:40:07 +02:00
Arturs Vonda
4cca382695
fix(core): take atom content entirely (#5321) 2024-07-19 13:49:15 +02:00
Nick Perez
07f4c03315
fix(core): configuring extensions should add to the parent's options not replace them (#5357)
* fix(core): configuring extensions should add to the parent's options not replace them

* fix: order of tests
2024-07-17 09:06:41 +02:00
Nick Perez
c540c7d2e8
fix: apply #5147 fix to marks and nodes resolves #4704 (#5156)
* fix: apply #5147 fix to marks and nodes

* fix: resolve Issue #4704 by reverting PR #4191

* test: more robust tests for nodes and marks too
2024-06-18 08:00:28 +02:00
Daniel Pivovarov
33de6fef67
fix(horizontal-rule): fix insertion behavior (#4898) 2024-06-14 04:51:52 +02:00
Yousef
fe78faab55
fix(core): mergeDeep now can merge nulls (#4088) 2024-06-12 08:36:44 +02:00
Nick the Sick
747985b3a7
chore: update package versions for prosemirror 2024-06-11 23:03:14 +02:00
Nick Perez
74bfdc5bef
feat: error handling of invalid content for a schema (#5178)
This change introduces two new top-level options to the editor: `enableContentCheck` & `onContentError` for dealing with content supplied that does not match the prose-mirror schema generated by the set of tiptap extensions.

`enableContentCheck` allows the app developer to opt into the behavior to check for invalid schemas (this change is otherwise backwards compatible).
When true, this will try to parse the document, and any content that does not match the schema will emit a `contentError` which can be listened to via the `onContentError` callback.
2024-06-04 09:32:54 +02:00
Nick the Sick
738c436a9f
fix: disable parsing javascript: links, add tests 2024-05-16 17:10:15 +02:00
Christofer Roth
980b54f62b fix(extension-link): use whitelist for allowed href values 2024-05-16 09:05:42 +02:00
Nick Perez
4db463c6bb
fix(core): configure should use the parent of the current instance, to avoid duplication (#5147) 2024-05-14 14:45:03 +02:00
Myles J
d6c71a838d
fix: unexpected renderText() for contentful nodes (#3410) 2024-04-06 01:29:46 +02:00
Lukas Hirt
099e10df92
fix: mark nocookie youtube url as valid when parsing html (#4883) 2024-02-19 10:32:57 +01:00
Cameron Hessler
e6947bad2d fix(extension-youtube) fix lint 2023-11-20 18:48:22 +01:00
Cameron Hessler
1bd714a408 fix(extension-youtube) change regex to disallow non-youtube domains 2023-11-20 18:48:22 +01:00
Cameron Hessler
7debf2baf0 fix(extension-youtube) Add fix for link too 2023-11-20 18:48:22 +01:00
Cameron Hessler
04a11355a7 fix(extension-youtube) XSS risk with src tag
Fixes risks outline in #4600 by verifying that any src urls are valid
youtube URLs before rendering as HTML. My thoughts are that this attack
vector would be difficult to use because the attacker would have to have
a way to manipualte the TipTap payload in a manner that bypasses the
youtube extension's `setYoutubeVideo` command, which already checks for
valid URLs.
2023-11-20 18:48:22 +01:00
bdbch
d689e2d9c1
React context implementation for Tiptap (#4192)
* feat(react): add react context implementation

* chore(docs): updated react docs & demos for new context

* chore(docs): added slot docs

* chore(docs): fix typo

* chore(react): use correct editor package

* fix typo in react installation docs

* update react typings to latest version

* fix types

---------

Co-authored-by: bdbch <dominik@bdbch.com>
2023-07-11 18:20:43 +02:00
Cameron Hessler
26610cdff3
fix(core) Nested chain not preserving dispatch state (#4152)
* Fix nested chain not preserving dispatch state

* Change test to read as sentence
2023-07-07 11:20:29 +02:00
Ben Asher
e97630c639
Require file extensions for imports and exports (#4001)
* Require .js endings

* add extension alias for cypress to resolve ts files with js endings
2023-06-30 21:03:49 +02:00
Dominik Biedebach
668c2a6592 tests: increase timeout 2023-03-03 13:00:14 +01:00