xref: /webtrees/public/ckeditor-4.15.1-custom/styles.js (revision b43e8d2bb2c20432b6d427f0f5d9a32679a9aa4f)
1*b43e8d2bSGreg Roach/**
2*b43e8d2bSGreg Roach * Copyright (c) 2003-2020, CKSource - Frederico Knabben. All rights reserved.
3*b43e8d2bSGreg Roach * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4*b43e8d2bSGreg Roach */
5*b43e8d2bSGreg Roach
6*b43e8d2bSGreg Roach// This file contains style definitions that can be used by CKEditor plugins.
7*b43e8d2bSGreg Roach//
8*b43e8d2bSGreg Roach// The most common use for it is the "stylescombo" plugin which shows the Styles drop-down
9*b43e8d2bSGreg Roach// list containing all styles in the editor toolbar. Other plugins, like
10*b43e8d2bSGreg Roach// the "div" plugin, use a subset of the styles for their features.
11*b43e8d2bSGreg Roach//
12*b43e8d2bSGreg Roach// If you do not have plugins that depend on this file in your editor build, you can simply
13*b43e8d2bSGreg Roach// ignore it. Otherwise it is strongly recommended to customize this file to match your
14*b43e8d2bSGreg Roach// website requirements and design properly.
15*b43e8d2bSGreg Roach//
16*b43e8d2bSGreg Roach// For more information refer to: https://ckeditor.com/docs/ckeditor4/latest/guide/dev_styles.html#style-rules
17*b43e8d2bSGreg Roach
18*b43e8d2bSGreg RoachCKEDITOR.stylesSet.add( 'default', [
19*b43e8d2bSGreg Roach	/* Block styles */
20*b43e8d2bSGreg Roach
21*b43e8d2bSGreg Roach	// These styles are already available in the "Format" drop-down list ("format" plugin),
22*b43e8d2bSGreg Roach	// so they are not needed here by default. You may enable them to avoid
23*b43e8d2bSGreg Roach	// placing the "Format" combo in the toolbar, maintaining the same features.
24*b43e8d2bSGreg Roach	/*
25*b43e8d2bSGreg Roach	{ name: 'Paragraph',		element: 'p' },
26*b43e8d2bSGreg Roach	{ name: 'Heading 1',		element: 'h1' },
27*b43e8d2bSGreg Roach	{ name: 'Heading 2',		element: 'h2' },
28*b43e8d2bSGreg Roach	{ name: 'Heading 3',		element: 'h3' },
29*b43e8d2bSGreg Roach	{ name: 'Heading 4',		element: 'h4' },
30*b43e8d2bSGreg Roach	{ name: 'Heading 5',		element: 'h5' },
31*b43e8d2bSGreg Roach	{ name: 'Heading 6',		element: 'h6' },
32*b43e8d2bSGreg Roach	{ name: 'Preformatted Text',element: 'pre' },
33*b43e8d2bSGreg Roach	{ name: 'Address',			element: 'address' },
34*b43e8d2bSGreg Roach	*/
35*b43e8d2bSGreg Roach
36*b43e8d2bSGreg Roach	{ name: 'Italic Title',		element: 'h2', styles: { 'font-style': 'italic' } },
37*b43e8d2bSGreg Roach	{ name: 'Subtitle',			element: 'h3', styles: { 'color': '#aaa', 'font-style': 'italic' } },
38*b43e8d2bSGreg Roach	{
39*b43e8d2bSGreg Roach		name: 'Special Container',
40*b43e8d2bSGreg Roach		element: 'div',
41*b43e8d2bSGreg Roach		styles: {
42*b43e8d2bSGreg Roach			padding: '5px 10px',
43*b43e8d2bSGreg Roach			background: '#eee',
44*b43e8d2bSGreg Roach			border: '1px solid #ccc'
45*b43e8d2bSGreg Roach		}
46*b43e8d2bSGreg Roach	},
47*b43e8d2bSGreg Roach
48*b43e8d2bSGreg Roach	/* Inline styles */
49*b43e8d2bSGreg Roach
50*b43e8d2bSGreg Roach	// These are core styles available as toolbar buttons. You may opt enabling
51*b43e8d2bSGreg Roach	// some of them in the Styles drop-down list, removing them from the toolbar.
52*b43e8d2bSGreg Roach	// (This requires the "stylescombo" plugin.)
53*b43e8d2bSGreg Roach	/*
54*b43e8d2bSGreg Roach	{ name: 'Strong',			element: 'strong', overrides: 'b' },
55*b43e8d2bSGreg Roach	{ name: 'Emphasis',			element: 'em'	, overrides: 'i' },
56*b43e8d2bSGreg Roach	{ name: 'Underline',		element: 'u' },
57*b43e8d2bSGreg Roach	{ name: 'Strikethrough',	element: 'strike' },
58*b43e8d2bSGreg Roach	{ name: 'Subscript',		element: 'sub' },
59*b43e8d2bSGreg Roach	{ name: 'Superscript',		element: 'sup' },
60*b43e8d2bSGreg Roach	*/
61*b43e8d2bSGreg Roach
62*b43e8d2bSGreg Roach	{ name: 'Marker',			element: 'span', attributes: { 'class': 'marker' } },
63*b43e8d2bSGreg Roach
64*b43e8d2bSGreg Roach	{ name: 'Big',				element: 'big' },
65*b43e8d2bSGreg Roach	{ name: 'Small',			element: 'small' },
66*b43e8d2bSGreg Roach	{ name: 'Typewriter',		element: 'tt' },
67*b43e8d2bSGreg Roach
68*b43e8d2bSGreg Roach	{ name: 'Computer Code',	element: 'code' },
69*b43e8d2bSGreg Roach	{ name: 'Keyboard Phrase',	element: 'kbd' },
70*b43e8d2bSGreg Roach	{ name: 'Sample Text',		element: 'samp' },
71*b43e8d2bSGreg Roach	{ name: 'Variable',			element: 'var' },
72*b43e8d2bSGreg Roach
73*b43e8d2bSGreg Roach	{ name: 'Deleted Text',		element: 'del' },
74*b43e8d2bSGreg Roach	{ name: 'Inserted Text',	element: 'ins' },
75*b43e8d2bSGreg Roach
76*b43e8d2bSGreg Roach	{ name: 'Cited Work',		element: 'cite' },
77*b43e8d2bSGreg Roach	{ name: 'Inline Quotation',	element: 'q' },
78*b43e8d2bSGreg Roach
79*b43e8d2bSGreg Roach	{ name: 'Language: RTL',	element: 'span', attributes: { 'dir': 'rtl' } },
80*b43e8d2bSGreg Roach	{ name: 'Language: LTR',	element: 'span', attributes: { 'dir': 'ltr' } },
81*b43e8d2bSGreg Roach
82*b43e8d2bSGreg Roach	/* Object styles */
83*b43e8d2bSGreg Roach
84*b43e8d2bSGreg Roach	{
85*b43e8d2bSGreg Roach		name: 'Styled Image (left)',
86*b43e8d2bSGreg Roach		element: 'img',
87*b43e8d2bSGreg Roach		attributes: { 'class': 'left' }
88*b43e8d2bSGreg Roach	},
89*b43e8d2bSGreg Roach
90*b43e8d2bSGreg Roach	{
91*b43e8d2bSGreg Roach		name: 'Styled Image (right)',
92*b43e8d2bSGreg Roach		element: 'img',
93*b43e8d2bSGreg Roach		attributes: { 'class': 'right' }
94*b43e8d2bSGreg Roach	},
95*b43e8d2bSGreg Roach
96*b43e8d2bSGreg Roach	{
97*b43e8d2bSGreg Roach		name: 'Compact Table',
98*b43e8d2bSGreg Roach		element: 'table',
99*b43e8d2bSGreg Roach		attributes: {
100*b43e8d2bSGreg Roach			cellpadding: '5',
101*b43e8d2bSGreg Roach			cellspacing: '0',
102*b43e8d2bSGreg Roach			border: '1',
103*b43e8d2bSGreg Roach			bordercolor: '#ccc'
104*b43e8d2bSGreg Roach		},
105*b43e8d2bSGreg Roach		styles: {
106*b43e8d2bSGreg Roach			'border-collapse': 'collapse'
107*b43e8d2bSGreg Roach		}
108*b43e8d2bSGreg Roach	},
109*b43e8d2bSGreg Roach
110*b43e8d2bSGreg Roach	{ name: 'Borderless Table',		element: 'table',	styles: { 'border-style': 'hidden', 'background-color': '#E6E6FA' } },
111*b43e8d2bSGreg Roach	{ name: 'Square Bulleted List',	element: 'ul',		styles: { 'list-style-type': 'square' } },
112*b43e8d2bSGreg Roach
113*b43e8d2bSGreg Roach	/* Widget styles */
114*b43e8d2bSGreg Roach
115*b43e8d2bSGreg Roach	{ name: 'Clean Image', type: 'widget', widget: 'image', attributes: { 'class': 'image-clean' } },
116*b43e8d2bSGreg Roach	{ name: 'Grayscale Image', type: 'widget', widget: 'image', attributes: { 'class': 'image-grayscale' } },
117*b43e8d2bSGreg Roach
118*b43e8d2bSGreg Roach	{ name: 'Featured Snippet', type: 'widget', widget: 'codeSnippet', attributes: { 'class': 'code-featured' } },
119*b43e8d2bSGreg Roach
120*b43e8d2bSGreg Roach	{ name: 'Featured Formula', type: 'widget', widget: 'mathjax', attributes: { 'class': 'math-featured' } },
121*b43e8d2bSGreg Roach
122*b43e8d2bSGreg Roach	{ name: '240p', type: 'widget', widget: 'embedSemantic', attributes: { 'class': 'embed-240p' }, group: 'size' },
123*b43e8d2bSGreg Roach	{ name: '360p', type: 'widget', widget: 'embedSemantic', attributes: { 'class': 'embed-360p' }, group: 'size' },
124*b43e8d2bSGreg Roach	{ name: '480p', type: 'widget', widget: 'embedSemantic', attributes: { 'class': 'embed-480p' }, group: 'size' },
125*b43e8d2bSGreg Roach	{ name: '720p', type: 'widget', widget: 'embedSemantic', attributes: { 'class': 'embed-720p' }, group: 'size' },
126*b43e8d2bSGreg Roach	{ name: '1080p', type: 'widget', widget: 'embedSemantic', attributes: { 'class': 'embed-1080p' }, group: 'size' },
127*b43e8d2bSGreg Roach
128*b43e8d2bSGreg Roach	// Adding space after the style name is an intended workaround. For now, there
129*b43e8d2bSGreg Roach	// is no option to create two styles with the same name for different widget types. See https://dev.ckeditor.com/ticket/16664.
130*b43e8d2bSGreg Roach	{ name: '240p ', type: 'widget', widget: 'embed', attributes: { 'class': 'embed-240p' }, group: 'size' },
131*b43e8d2bSGreg Roach	{ name: '360p ', type: 'widget', widget: 'embed', attributes: { 'class': 'embed-360p' }, group: 'size' },
132*b43e8d2bSGreg Roach	{ name: '480p ', type: 'widget', widget: 'embed', attributes: { 'class': 'embed-480p' }, group: 'size' },
133*b43e8d2bSGreg Roach	{ name: '720p ', type: 'widget', widget: 'embed', attributes: { 'class': 'embed-720p' }, group: 'size' },
134*b43e8d2bSGreg Roach	{ name: '1080p ', type: 'widget', widget: 'embed', attributes: { 'class': 'embed-1080p' }, group: 'size' }
135*b43e8d2bSGreg Roach
136*b43e8d2bSGreg Roach] );
137