mirror of
https://github.com/strapi/strapi.git
synced 2025-12-08 13:29:57 +00:00
45 lines
2.3 KiB
JavaScript
45 lines
2.3 KiB
JavaScript
export const SELECT_OPTIONS = [
|
|
{ id: 'Add a title', value: '' },
|
|
{ id: 'Title H1', value: '# innerText.H1' },
|
|
{ id: 'Title H2', value: '## innerText.H2' },
|
|
{ id: 'Title H3', value: '### innerText.H3' },
|
|
{ id: 'Title H4', value: '#### innerText.H4'},
|
|
{ id: 'Title H5', value: '##### innerText.H5' },
|
|
{ id: 'Title H6', value: '###### innerText.H6' },
|
|
];
|
|
|
|
// NOTE: I leave that as a reminder
|
|
export const CONTROLS = [
|
|
[
|
|
{label: 'B', style: 'BOLD', handler: 'toggleInlineStyle' },
|
|
{label: 'I', style: 'ITALIC', className: 'styleButtonItalic', handler: 'toggleInlineStyle' },
|
|
{label: 'U', style: 'UNDERLINE', handler: 'toggleInlineStyle' },
|
|
{label: 'UL', style: 'unordered-list-item', className: 'styleButtonUL', hideLabel: true, handler: 'toggleBlockType' },
|
|
{label: 'OL', style: 'ordered-list-item', className: 'styleButtonOL', hideLabel: true, handler: 'toggleBlockType' },
|
|
],
|
|
[
|
|
{label: '<>', style: 'code-block', handler: 'toggleBlockType' },
|
|
{label: 'quotes', style: 'blockquote', className: 'styleButtonBlockQuote', hideLabel: true, handler: 'toggleBlockType' },
|
|
],
|
|
];
|
|
|
|
export const NEW_CONTROLS = [
|
|
[
|
|
{label: 'B', style: 'BOLD', handler: 'addEntity', text: '**innerText**' },
|
|
{label: 'I', style: 'ITALIC', className: 'styleButtonItalic', handler: 'addEntity', text: '*innerText*' },
|
|
{label: 'U', style: 'UNDERLINE', handler: 'addEntity', text: '__innerText__' },
|
|
{label: 'UL', style: 'unordered-list-item', className: 'styleButtonUL', hideLabel: true, handler: 'addEntity', text: '- innerText' },
|
|
{label: 'OL', style: 'ordered-list-item', className: 'styleButtonOL', hideLabel: true, handler: 'addEntity', text: '1. innerText' },
|
|
],
|
|
[
|
|
{label: '<>', style: 'code-block', handler: 'addEntity', text: '```innerText```' },
|
|
{label: 'img', style: 'IMG', className: 'styleButtonImg', hideLabel: true, handler: 'addLinkMediaBlockWithSelection', text: '' },
|
|
{label: 'Link', style: 'LINK', className: 'styleButtonLink',hideLabel: true, handler: 'addEntity', text: '[innerText](link)' },
|
|
{label: 'quotes', style: 'blockquote', className: 'styleButtonBlockQuote', hideLabel: true, handler: 'addEntity', text: '> innerText' },
|
|
],
|
|
];
|
|
|
|
|
|
export const END_REPLACER = '_*</u>`](link)';
|
|
export const START_REPLACER = '_*<u>-`>#[ ![ 1. ';
|