Socket
Socket
Sign inDemoInstall

prosemirror-model

Package Overview
Dependencies
Maintainers
1
Versions
84
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

prosemirror-model - npm Package Compare versions

Comparing version 1.6.1 to 1.6.2

6

CHANGELOG.md

@@ -0,1 +1,7 @@

## 1.6.2 (2018-10-01)
### Bug fixes
Prevent [`ContentMatch.findWrapping`](https://prosemirror.net/docs/ref/#model.ContentMatch.findWrapping) from returning node types with required attributes.
## 1.6.1 (2018-07-24)

@@ -2,0 +8,0 @@

2

package.json
{
"name": "prosemirror-model",
"version": "1.6.1",
"version": "1.6.2",
"description": "ProseMirror's document model",

@@ -5,0 +5,0 @@ "main": "dist/index.js",

@@ -119,3 +119,3 @@ import {Fragment} from "./fragment"

let type = match.next[i]
if (!type.isLeaf && !(type.name in seen) && (!current.type || match.next[i + 1].validEnd)) {
if (!type.isLeaf && !type.hasRequiredAttrs() && !(type.name in seen) && (!current.type || match.next[i + 1].validEnd)) {
active.push({match: type.contentMatch, type, via: current})

@@ -122,0 +122,0 @@ seen[type.name] = true

@@ -285,3 +285,5 @@ import {Fragment} from "./fragment"

contentMatchAt(index) {
return this.type.contentMatch.matchFragment(this.content, 0, index)
let match = this.type.contentMatch.matchFragment(this.content, 0, index)
if (!match) throw new Error("Called contentMatchAt on a node with invalid content")
return match
}

@@ -288,0 +290,0 @@

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc