Explorar el Código

Removed unfinished feature file.

Oskar Wrobel hace 9 años
padre
commit
5bb896f7e7

+ 0 - 65
packages/ckeditor5-link/src/link.js

@@ -1,65 +0,0 @@
-/**
- * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
- * For licensing, see LICENSE.md.
- */
-
-import Feature from '../core/feature.js';
-import LinkEngine from './linkengine.js';
-import ButtonController from '../ui/button/button.js';
-import ButtonView from '../ui/button/buttonview.js';
-import Model from '../ui/model.js';
-
-/**
- * The link feature.
- *
- * It uses the {@link basic-styles.LinkEngine link engine feature}.
- *
- * @memberOf link
- * @extends core.Feature
- */
-export default class Link extends Feature {
-	/**
-	 * @inheritDoc
-	 */
-	static get requires() {
-		return [ LinkEngine ];
-	}
-
-	/**
-	 * @inheritDoc
-	 */
-	init() {
-		const editor = this.editor;
-		const t = editor.t;
-		const linkCommand = editor.commands.get( 'link' );
-
-		// Create button model.
-		const buttonModel = new Model( {
-			isEnabled: true,
-			isOn: false,
-			label: t( 'Link' ),
-			icon: 'link'
-		} );
-
-		const unlinkButtonModel = new Model( {
-			isEnabled: true,
-			isOn: false,
-			label: t( 'Unlink' ),
-			icon: 'unlink'
-		} );
-
-		// Button <-> Command binding.
-		buttonModel.bind( 'isOn', 'isEnabled' ).to( linkCommand, 'hasValue', 'isEnabled' );
-
-		// Execute linking.
-		const hrefValue = 'http://www.cksource.com'; // Temporary href value.
-		this.listenTo( buttonModel, 'execute', () => editor.execute( 'link', hrefValue ) );
-
-		// Execute unlinking.
-		this.listenTo( unlinkButtonModel, 'execute', () => editor.execute( 'unlink' ) );
-
-		// Add link button to feature components.
-		editor.ui.featureComponents.add( 'link', ButtonController, ButtonView, buttonModel );
-		editor.ui.featureComponents.add( 'unlink', ButtonController, ButtonView, unlinkButtonModel );
-	}
-}

+ 0 - 7
packages/ckeditor5-link/tests/manual/link.html

@@ -1,7 +0,0 @@
-<head>
-	<link rel="stylesheet" href="%APPS_DIR%ckeditor/build/modules/amd/theme/ckeditor.css">
-</head>
-
-<div id="editor">
-	<p>This is an <a href="http://ckeditor.com">CKEditor5</a> from <a href="http://cksource.com">CKSource</a>.</p>
-</div>

+ 0 - 19
packages/ckeditor5-link/tests/manual/link.js

@@ -1,19 +0,0 @@
-/**
- * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
- * For licensing, see LICENSE.md.
- */
-
-/* globals console:false, window, document */
-
-import ClassicEditor from '/ckeditor5/editor-classic/classic.js';
-
-ClassicEditor.create( document.querySelector( '#editor' ), {
-	features: [ 'link', 'typing', 'paragraph', 'enter', 'undo' ],
-	toolbar: [ 'link', 'unlink', 'undo', 'redo' ]
-} )
-.then( editor => {
-	window.editor = editor;
-} )
-.catch( err => {
-	console.error( err.stack );
-} );

+ 0 - 5
packages/ckeditor5-link/tests/manual/link.md

@@ -1,5 +0,0 @@
-@bender-ui: collapsed
-
-## Link
-
-1. Test the link feature live.