8
0

custom-text-alignment-toolbar.js 674 B

123456789101112131415161718192021222324252627
  1. /**
  2. * @license Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
  3. * For licensing, see LICENSE.md.
  4. */
  5. /* globals ClassicEditor, console, window, document */
  6. import { TOKEN_URL } from '@ckeditor/ckeditor5-cloudservices/tests/_utils/cloudservices-config';
  7. ClassicEditor
  8. .create( document.querySelector( '#snippet-custom-text-alignment-toolbar' ), {
  9. toolbar: {
  10. items: [
  11. 'headings', '|', 'alignLeft', 'alignRight', 'alignCenter', 'alignJustify'
  12. ],
  13. viewportTopOffset: 60
  14. },
  15. cloudServices: {
  16. tokenUrl: TOKEN_URL
  17. }
  18. } )
  19. .then( editor => {
  20. window.editor = editor;
  21. } )
  22. .catch( err => {
  23. console.error( err.stack );
  24. } );