Skip to content
Snippets Groups Projects
Commit c290a6e8 authored by chris's avatar chris
Browse files

add new tables src

parent 90815956
No related branches found
No related tags found
1 merge request!488Tables caption
Showing with 2531 additions and 31 deletions
......@@ -6,7 +6,6 @@
"@guardian/prosemirror-invisibles": "^1.2.0",
"@pubsweet/ui-toolkit": "^2.3.1",
"fontsource-merriweather": "^3.0.9",
"prosemirror-tables": "1.3.4",
"react": "^18.2.0",
"react-dom": "^18.2.0",
"react-panelgroup": "^1.0.10",
......
import { emDash, ellipsis } from 'prosemirror-inputrules';
import { debounce } from 'lodash';
import { columnResizing, tableEditing } from 'prosemirror-tables';
import {
InlineAnnotationsService,
AnnotationToolGroupService,
......@@ -150,8 +150,6 @@ export default {
},
},
PmPlugins: [
columnResizing(),
tableEditing(),
invisibles([hardBreak()]),
disallowPasteImagesPlugin(() =>
onWarning(
......
import { emDash, ellipsis } from 'prosemirror-inputrules';
import { columnResizing, tableEditing } from 'prosemirror-tables';
import {
AnnotationToolGroupService,
ImageService,
......@@ -79,7 +78,7 @@ export default {
TitleService: { updateTitle },
EnableTrackChangeService: { enabled: false },
PmPlugins: [columnResizing(), tableEditing(), invisibles([hardBreak()])],
PmPlugins: [invisibles([hardBreak()])],
CustomTagService: {
tags: [
{ label: 'custom-tag-label-1', tagType: 'inline' },
......
import { emDash, ellipsis } from 'prosemirror-inputrules';
import { columnResizing, tableEditing } from 'prosemirror-tables';
import {
InlineAnnotationsService,
AnnotationToolGroupService,
......@@ -130,7 +129,7 @@ export default {
RulesService: [emDash, ellipsis],
ImageService: { showAlt: true },
PmPlugins: [columnResizing(), tableEditing(), invisibles([hardBreak()])],
PmPlugins: [invisibles([hardBreak()])],
services: [
// new ExternalAPIContentService(),
new QuestionsService(),
......
import { emDash, ellipsis } from 'prosemirror-inputrules';
import { debounce } from 'lodash';
import { columnResizing, tableEditing } from 'prosemirror-tables';
import {
InlineAnnotationsService,
AnnotationToolGroupService,
......@@ -191,7 +191,7 @@ export default {
reject: true,
},
},
PmPlugins: [columnResizing(), tableEditing(), invisibles([hardBreak()])],
PmPlugins: [invisibles([hardBreak()])],
CustomTagService: {
tags: [
{ label: 'custom-tag-label-1', tagType: 'inline' },
......
......@@ -34,7 +34,6 @@ export default {
'react-dropdown',
'uuid',
'prop-types',
'prosemirror-tables',
'wax-prosemirror-services',
],
};
......@@ -29,7 +29,6 @@
"prosemirror-model": "1.19.0",
"prosemirror-schema-list": "1.3.0",
"prosemirror-state": "1.4.2",
"prosemirror-tables": "1.3.4",
"prosemirror-transform": "1.7.1",
"prosemirror-view": "1.30.2",
"react-dropdown": "^1.6.2",
......
......@@ -42,7 +42,6 @@ export default {
'react-dom',
'react-dropdown',
'lodash',
'prosemirror-tables',
'prosemirror-schema-list',
'prosemirror-model',
'prosemirror-inputrules',
......
import { Service } from 'wax-prosemirror-core';
import { tableNodes, goToNextCell } from 'prosemirror-tables';
import { tableNodes, goToNextCell } from '../tableSrc';
import Table from './Table';
class InsertTableService extends Service {
......
......@@ -8,8 +8,8 @@ import React, {
createRef,
} from 'react';
import styled from 'styled-components';
import * as tablesFn from 'prosemirror-tables';
import { WaxContext, Icon, useOnClickOutside } from 'wax-prosemirror-core';
import * as tablesFn from '../tableSrc';
const Wrapper = styled.div`
opacity: ${props => (props.disabled ? '0.4' : '1')};
......
This diff is collapsed.
......@@ -12053,7 +12053,7 @@ prosemirror-keymap@1.2.1:
prosemirror-state "^1.0.0"
w3c-keyname "^2.2.0"
 
prosemirror-keymap@^1.0.0, prosemirror-keymap@^1.1.2:
prosemirror-keymap@^1.0.0:
version "1.1.4"
resolved "https://registry.yarnpkg.com/prosemirror-keymap/-/prosemirror-keymap-1.1.4.tgz#8b481bf8389a5ac40d38dbd67ec3da2c7eac6a6d"
integrity sha512-Al8cVUOnDFL4gcI5IDlG6xbZ0aOD/i3B17VT+1JbHWDguCgt/lBHVTHUBcKvvbSg6+q/W4Nj1Fu6bwZSca3xjg==
......@@ -12061,7 +12061,7 @@ prosemirror-keymap@^1.0.0, prosemirror-keymap@^1.1.2:
prosemirror-state "^1.0.0"
w3c-keyname "^2.2.0"
 
prosemirror-model@1.19.0, prosemirror-model@^1.0.0, prosemirror-model@^1.16.0, prosemirror-model@^1.2.0, prosemirror-model@^1.8.1:
prosemirror-model@1.19.0, prosemirror-model@^1.0.0, prosemirror-model@^1.16.0, prosemirror-model@^1.2.0:
version "1.19.0"
resolved "https://registry.yarnpkg.com/prosemirror-model/-/prosemirror-model-1.19.0.tgz#d7ad9a65ada0bb12196f64fe0dd4fc392c841c29"
integrity sha512-/CvFGJnwc41EJSfDkQLly1cAJJJmBpZwwUJtwZPTjY2RqZJfM8HVbCreOY/jti8wTRbVyjagcylyGoeJH/g/3w==
......@@ -12092,7 +12092,7 @@ prosemirror-schema-list@^1.0.0:
prosemirror-model "^1.0.0"
prosemirror-transform "^1.0.0"
 
prosemirror-state@1.4.2, prosemirror-state@^1.0.0, prosemirror-state@^1.2.2, prosemirror-state@^1.3.1:
prosemirror-state@1.4.2, prosemirror-state@^1.0.0, prosemirror-state@^1.2.2:
version "1.4.2"
resolved "https://registry.yarnpkg.com/prosemirror-state/-/prosemirror-state-1.4.2.tgz#f93bd8a33a4454efab917ba9b738259d828db7e5"
integrity sha512-puuzLD2mz/oTdfgd8msFbe0A42j5eNudKAAPDB0+QJRw8cO1ygjLmhLrg9RvDpf87Dkd6D4t93qdef00KKNacQ==
......@@ -12101,17 +12101,6 @@ prosemirror-state@1.4.2, prosemirror-state@^1.0.0, prosemirror-state@^1.2.2, pro
prosemirror-transform "^1.0.0"
prosemirror-view "^1.27.0"
 
prosemirror-tables@1.3.4:
version "1.3.4"
resolved "https://registry.yarnpkg.com/prosemirror-tables/-/prosemirror-tables-1.3.4.tgz#0b7cc16d49f90c5b834c9f29291c545478ce9ab0"
integrity sha512-z6uLSQ1BLC3rgbGwZmpfb+xkdvD7W/UOsURDfognZFYaTtc0gsk7u/t71Yijp2eLflVpffMk6X0u0+u+MMDvIw==
dependencies:
prosemirror-keymap "^1.1.2"
prosemirror-model "^1.8.1"
prosemirror-state "^1.3.1"
prosemirror-transform "^1.2.1"
prosemirror-view "^1.13.3"
prosemirror-test-builder@^1.0.1:
version "1.0.3"
resolved "https://registry.yarnpkg.com/prosemirror-test-builder/-/prosemirror-test-builder-1.0.3.tgz#9706b6e021efe82830b479797923d835f4ca12a3"
......@@ -12121,7 +12110,7 @@ prosemirror-test-builder@^1.0.1:
prosemirror-schema-basic "^1.0.0"
prosemirror-schema-list "^1.0.0"
 
prosemirror-transform@1.7.1, prosemirror-transform@^1.0.0, prosemirror-transform@^1.1.0, prosemirror-transform@^1.2.1:
prosemirror-transform@1.7.1, prosemirror-transform@^1.0.0, prosemirror-transform@^1.1.0:
version "1.7.1"
resolved "https://registry.yarnpkg.com/prosemirror-transform/-/prosemirror-transform-1.7.1.tgz#b516e818c3add0bdf960f4ca8ccb9d057a3ba21b"
integrity sha512-VteoifAfpt46z0yEt6Fc73A5OID9t/y2QIeR5MgxEwTuitadEunD/V0c9jQW8ziT8pbFM54uTzRLJ/nLuQjMxg==
......@@ -12135,7 +12124,7 @@ prosemirror-transform@^1.7.3:
dependencies:
prosemirror-model "^1.0.0"
 
prosemirror-view@1.30.2, prosemirror-view@^1.0.0, prosemirror-view@^1.1.0, prosemirror-view@^1.13.3, prosemirror-view@^1.27.0, prosemirror-view@^1.5.1:
prosemirror-view@1.30.2, prosemirror-view@^1.0.0, prosemirror-view@^1.1.0, prosemirror-view@^1.27.0, prosemirror-view@^1.5.1:
version "1.30.2"
resolved "https://registry.yarnpkg.com/prosemirror-view/-/prosemirror-view-1.30.2.tgz#57a9d15c5baa454f0d0f4a3028ddbd9be1e8ed9b"
integrity sha512-nTNzZvalQf9kHeEyO407LiV6DoOs/pXsid88UqW9Vvybo4ozJW2PJhkfZUxCUF1hR/9vJLdhxX84wuw9P9HsXA==
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment