Skip to content

Commit 5ca0eb4

Browse files
committed
Update dependencies 8/11/22
1 parent 305b1a2 commit 5ca0eb4

File tree

10 files changed

+5354
-7107
lines changed

10 files changed

+5354
-7107
lines changed

package-lock.json

Lines changed: 5130 additions & 6841 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -44,32 +44,32 @@
4444
],
4545
"license": "MIT",
4646
"dependencies": {
47-
"mobiledoc-dom-renderer": "0.7.0",
47+
"mobiledoc-dom-renderer": "0.7.1",
4848
"mobiledoc-text-renderer": "0.4.1"
4949
},
5050
"devDependencies": {
51-
"@rollup/plugin-alias": "^3.1.1",
51+
"@rollup/plugin-alias": "^3.1.9",
5252
"@rollup/plugin-commonjs": "^15.0.0",
5353
"@rollup/plugin-node-resolve": "^9.0.0",
5454
"@rollup/plugin-typescript": "^5.0.2",
55-
"@types/jquery": "^3.5.2",
56-
"@types/qunit": "^2.9.5",
55+
"@types/jquery": "^3.5.14",
56+
"@types/qunit": "^2.19.2",
5757
"@typescript-eslint/eslint-plugin": "^3.6.1",
5858
"@typescript-eslint/parser": "^3.6.1",
59-
"conventional-changelog-cli": "^2.0.34",
59+
"conventional-changelog-cli": "^2.2.2",
6060
"eslint": "^7.4.0",
6161
"eslint-config-prettier": "^6.11.0",
62-
"jquery": "^3.5.1",
62+
"jquery": "^3.6.0",
6363
"jsdoc": "^3.6.5",
64-
"prettier": "^2.1.1",
65-
"qunit": "^2.11.1",
66-
"rollup": "^2.26.9",
67-
"rollup-plugin-copy": "^3.3.0",
64+
"prettier": "^2.7.1",
65+
"qunit": "^2.19.1",
66+
"rollup": "^2.77.3",
67+
"rollup-plugin-copy": "^3.4.0",
6868
"rollup-plugin-glob-import": "^0.4.5",
6969
"rollup-plugin-serve": "^1.0.4",
7070
"saucie": "^3.3.3",
7171
"testem": "^3.2.0",
72-
"tslib": "^2.0.0",
72+
"tslib": "^2.4.0",
7373
"typescript": "^3.9.3"
7474
},
7575
"prettier": {

src/js/editor/edit-state.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,7 @@ export default class EditState {
132132
// In addition, to catch changes from ul -> ol, we keep track of the
133133
// un-nested tag names (otherwise we'd only see li -> li change)
134134
state.activeSectionTagNames = state.activeSections!.map(s => {
135-
return s.isNested ? ((s.parent as unknown) as TagNameable).tagName : ((s as unknown) as TagNameable).tagName
135+
return s.isNested ? (s.parent as unknown as TagNameable).tagName : (s as unknown as TagNameable).tagName
136136
})
137137
state.activeSectionAttributes = this._readSectionAttributes(state.activeSections!)
138138

src/js/editor/post.ts

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -694,13 +694,13 @@ export default class PostEditor {
694694

695695
_replaceSection(section: Section, newSections: Section[]) {
696696
let nextSection = section.next
697-
let collection = ((section.parent as unknown) as HasChildSections).sections
697+
let collection = (section.parent as unknown as HasChildSections).sections
698698

699699
let nextNewSection = newSections[0]
700700
if (isMarkupSection(nextNewSection) && isListItem(section)) {
701701
// put the new section after the ListSection (section.parent)
702702
// instead of after the ListItem
703-
collection = ((section.parent.parent as unknown) as HasChildSections).sections
703+
collection = (section.parent.parent as unknown as HasChildSections).sections
704704
nextSection = section.parent.next
705705
}
706706

@@ -922,7 +922,7 @@ export default class PostEditor {
922922
let attribute = `data-md-${key}`
923923

924924
post.walkMarkerableSections(range, section => {
925-
const cbSection: Attributable = isListItem(section) ? section.parent : ((section as unknown) as Attributable)
925+
const cbSection: Attributable = isListItem(section) ? section.parent : (section as unknown as Attributable)
926926

927927
if (cb(cbSection, attribute) === true) {
928928
this._markDirty(section)
@@ -1090,7 +1090,7 @@ export default class PostEditor {
10901090

10911091
_changeSectionToListItem(section: ListSection | Markerable, newTagName: string) {
10921092
let isAlreadyCorrectListItem =
1093-
section.isListItem && ((section.parent as unknown) as TagNameable).tagName === newTagName
1093+
section.isListItem && (section.parent as unknown as TagNameable).tagName === newTagName
10941094

10951095
if (isAlreadyCorrectListItem) {
10961096
return section
@@ -1149,7 +1149,7 @@ export default class PostEditor {
11491149
const activeSection = this.editor.activeSection
11501150
const nextSection = activeSection && activeSection.next
11511151

1152-
const collection = (this.editor.post.sections as unknown) as LinkedList<Section>
1152+
const collection = this.editor.post.sections as unknown as LinkedList<Section>
11531153
this.insertSectionBefore(collection, section, nextSection)
11541154
}
11551155

src/js/editor/text-input-handler.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ class TextInputHandler {
5757
const { head } = range
5858
const { section } = head
5959

60-
let preText = ((section! as unknown) as Markerable).textUntil(head) + string
60+
let preText = (section! as unknown as Markerable).textUntil(head) + string
6161

6262
for (let i = 0; i < this._handlers.length; i++) {
6363
let handler = this._handlers[i]

src/js/index.ts

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,4 +9,16 @@ import Renderer, { MOBILEDOC_VERSION } from './renderers/mobiledoc'
99
import DOMParser from './parsers/dom'
1010
import PostNodeBuilder from './models/post-node-builder'
1111

12-
export { Editor, UI, ImageCard, Range, Position, Error, DOMParser, PostNodeBuilder, Renderer, VERSION, MOBILEDOC_VERSION }
12+
export {
13+
Editor,
14+
UI,
15+
ImageCard,
16+
Range,
17+
Position,
18+
Error,
19+
DOMParser,
20+
PostNodeBuilder,
21+
Renderer,
22+
VERSION,
23+
MOBILEDOC_VERSION,
24+
}

src/js/models/_markerable.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ export default abstract class Markerable extends tagNameable(Section) implements
4040

4141
clone(): this {
4242
const newMarkers = this.markers.map(m => m.clone())
43-
return (this.builder.createMarkerableSection(this.type, this.tagName, newMarkers) as any) as this
43+
return this.builder.createMarkerableSection(this.type, this.tagName, newMarkers) as any as this
4444
}
4545

4646
get isBlank() {

src/js/renderers/editor-dom.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -567,7 +567,7 @@ let destroyHooks = {
567567
}
568568

569569
// an atom is a kind of marker so just call its destroy hook vs copying here
570-
destroyHooks[Type.MARKER](renderNode, (atom as unknown) as Marker)
570+
destroyHooks[Type.MARKER](renderNode, atom as unknown as Marker)
571571
},
572572
}
573573

src/js/utils/cursor/position.ts

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,8 @@ const { FORWARD, BACKWARD } = Direction
1818
// generated via http://xregexp.com/ to cover chars that \w misses
1919
// (new XRegExp('\\p{Alphabetic}|[0-9]|_|:')).toString()
2020
// eslint-disable-next-line no-misleading-character-class
21-
const WORD_CHAR_REGEX = /[A-Za-zªµºÀ-ÖØ-öø-ˁˆ-ˑˠ-ˤˬˮͅͰ-ʹͶͷͺ-ͽͿΆΈ-ΊΌΎ-ΡΣ-ϵϷ-ҁҊ-ԯԱ-Ֆՙա-ևְ-ׇֽֿׁׂׅׄא-תװ-ײؐ-ؚؠ-ٗٙ-ٟٮ-ۓە-ۜۡ-ۭۨ-ۯۺ-ۼۿܐ-ܿݍ-ޱߊ-ߪߴߵߺ----------------------------------------------------------------------------ൿ--------------------က---------------------------------------------------------------ᶿ-----------------------------------------ⷿ--------------ꀀ-----------------------ꦿ------------------------------------------]|[0-9]|_|:/
21+
const WORD_CHAR_REGEX =
22+
/[A-Za-zªµºÀ-ÖØ-öø-ˁˆ-ˑˠ-ˤˬˮͅͰ-ʹͶͷͺ-ͽͿΆΈ-ΊΌΎ-ΡΣ-ϵϷ-ҁҊ-ԯԱ-Ֆՙա-ևְ-ׇֽֿׁׂׅׄא-תװ-ײؐ-ؚؠ-ٗٙ-ٟٮ-ۓە-ۜۡ-ۭۨ-ۯۺ-ۼۿܐ-ܿݍ-ޱߊ-ߪߴߵߺ----------------------------------------------------------------------------ൿ--------------------က---------------------------------------------------------------ᶿ-----------------------------------------ⷿ--------------ꀀ-----------------------ꦿ------------------------------------------]|[0-9]|_|:/
2223

2324
function findParentSectionFromNode(renderTree: RenderTree, node: Node) {
2425
let renderNode = renderTree.findRenderNodeFromElement(node, renderNode => (renderNode.postNode as Section).isSection)
@@ -498,11 +499,11 @@ class BlankPosition extends Position {
498499
}
499500

500501
move(): Position {
501-
return (this as unknown) as Position
502+
return this as unknown as Position
502503
}
503504

504505
moveWord(): Position {
505-
return (this as unknown) as Position
506+
return this as unknown as Position
506507
}
507508

508509
get markerPosition() {

0 commit comments

Comments
 (0)