User (collaboration-core)
@ckeditor/ckeditor5-collaboration-core/src/users
The representation of a single user that is involved in document editing.
Filtering
Properties
-
avatar : undefined | string
module:collaboration-core/users~User#avatar
The URL pointing to the image with the avatar of the user.
If avatar is not set, default avatar is used.
-
color : Color
module:collaboration-core/users~User#color
CSS colors classes object for the user.
-
id : string
module:collaboration-core/users~User#id
The ID of the user.
-
The initials of the user.
The initials are composed from the user name's first and last words:
- for
Joe Doe
, the initials areJD
, - for
Anonymous
the initials areA
, - for
Katie John-Newman
the initials areKJ
, - for
Adam Daniel Smith
the initials areAS
.
- for
-
Is
true
for the anonymous user,false
otherwise.The anonymous user is used when there is no defined user for given resource.
The situations when the anonymous user is used will depend on your application. For example, it can be used when the editor can be used by "guest" users of your application, or when the original user's account was removed.
-
Is
true
for the local user. -
name : string
module:collaboration-core/users~User#name
The name of the user.
Methods
-
constructor( data )
module:collaboration-core/users~User#constructor
Parameters
data : UserData
User data.
Every day, we work hard to keep our documentation complete. Have you spotted outdated information? Is something missing? Please report it via our issue tracker.