Skip to content
This repository has been archived by the owner on Nov 25, 2024. It is now read-only.

Commit

Permalink
feat: adding table & cell properties & table caption support
Browse files Browse the repository at this point in the history
  • Loading branch information
letsbug committed Aug 20, 2022
1 parent 4476230 commit fa2c5be
Show file tree
Hide file tree
Showing 3 changed files with 28 additions and 13 deletions.
12 changes: 6 additions & 6 deletions docs/src/app.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@ import type { MceConfig, MceBase } from '../../types';
import { presetData } from './data';

const navConf = [
{ name: 'Classic Build', type: 'classic' },
{ name: 'Balloon Build', type: 'balloon' },
{ name: 'Inline Build', type: 'inline' },
{ name: 'Classic Mode', type: 'classic' },
{ name: 'Balloon Mode', type: 'balloon' },
{ name: 'Inline Mode', type: 'inline' },
];

let ckInstance: MceBase | null = null;
Expand Down Expand Up @@ -88,9 +88,9 @@ const App = defineComponent({
const mainClass = {
'ck-main': true,
// 'build-decoupled': type.value === 'BuildDecoupled',
'build-balloon': type.value === 'BuildBalloon',
'build-classic': type.value === 'BuildClassic',
'build-inline': type.value === 'BuildInline',
'build-balloon': type.value === 'balloon',
'build-classic': type.value === 'classic',
'build-inline': type.value === 'inline',
};
const navs = navConf.map((n) => (
<li class={{ active: n.type === type.value }} onClick={() => checkType(n.type)}>
Expand Down
3 changes: 1 addition & 2 deletions docs/src/style/index.css
Original file line number Diff line number Diff line change
Expand Up @@ -91,8 +91,7 @@ body {
top: 0;
}

.ck-main.build-classic,
.ck-main.build-inline {
.ck-main {
width: 800px;
}

Expand Down
26 changes: 21 additions & 5 deletions src/configs.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,14 @@ import { MediaEmbed, MediaEmbedToolbar } from '@ckeditor/ckeditor5-media-embed/s
import { HtmlEmbed } from '@ckeditor/ckeditor5-html-embed/src';
import { Paragraph } from '@ckeditor/ckeditor5-paragraph/src';
import { PageBreak } from '@ckeditor/ckeditor5-page-break/src';
import { Table, TableToolbar, TableColumnResize } from '@ckeditor/ckeditor5-table/src';
import {
Table,
TableToolbar,
TableColumnResize,
TableProperties,
TableCellProperties,
TableCaption,
} from '@ckeditor/ckeditor5-table/src';
import { TextTransformation } from '@ckeditor/ckeditor5-typing/src';
import { RemoveFormat } from '@ckeditor/ckeditor5-remove-format/src';
import { Indent } from '@ckeditor/ckeditor5-indent/src';
Expand Down Expand Up @@ -51,6 +58,9 @@ export const builtins = [
Essentials,
BlockToolbar,
BalloonToolbar,
FindAndReplace,

TextTransformation,
Alignment,
Autoformat,
Bold,
Expand All @@ -61,30 +71,36 @@ export const builtins = [
BlockQuote,
Heading,
Indent,
Subscript,
Superscript,

ImageBlock,
ImageStyle,
ImageToolbar,
ImageUpload,
ImageResize,

Link,
LinkImage,

List,
MediaEmbed,
MediaEmbedToolbar,
HtmlEmbed,
Paragraph,
PageBreak,
PasteFromOffice,

Table,
TableToolbar,
TableColumnResize,
TextTransformation,
Subscript,
Superscript,
TableProperties,
TableCellProperties,
TableCaption,

SimpleAdapter,
RemoveFormat,
Highlight,
FindAndReplace,

// custom plugins with @hlw/ckeditor5-plugins
Outline,
Expand Down

0 comments on commit fa2c5be

Please sign in to comment.