Interface

UsersConfig (collaboration-core)

@ckeditor/ckeditor5-collaboration-core/src/config

interface

The configuration of the Users features.

ClassicEditor
	.create( {
		users: ... // Users configuration.
	} )
	.then( ... )
	.catch( ... );

See all editor options.

Filtering

Properties

  • anonymousUserId : string | undefined

    User ID value that will be used for the anonymous user.

  • colorsCount : number | undefined

    Number of defined colors that are randomly assigned to users.

  • getInitialsCallback : ( string ) => string | undefined

    A callback function that customizes the way user initials are generated.

    If provided, this function will be called with the user's full name as the argument, and it should return a string representing the user's initials.

    Example usage:

    ClassicEditor
    	.create( {
    		users: {
    			getInitialsCallback: ( name: string ) => {
        			// Custom logic to generate initials.
        			return name.split( ' ' )[ 0 ].charAt( 0 ) + name.split( ' ' )[ 1 ].charAt( 0 );
    			}
    		}
    	} )
    	.then( ... )
    	.catch( ... );