Skip to content

Docs issue report from "features/collaboration/track-changes/track-changes-custom-features.html" #15188

Open
@Anamon

Description

Origin URL

https://ckeditor.com/docs/ckeditor5/latest/features/collaboration/track-changes/track-changes-custom-features.html

Project version

40.0.0

Is the information outdated? How?

The example code in Insertions and deletions doesn't work with the official typings. It instructs to use:

const trackChangesEditing = editor.plugins.get( 'TrackChangesEditing' );
trackChangesEditing._descriptionFactory.registerElementLabel(
    'pageBreak',

    quantity => t( {
        string: 'page break',
        plural: '%0 page breaks',
        id: 'ELEMENT_PAGE_BREAK'
    }, quantity )
);

to set the custom suggestion descriptions. However, _descriptionFactory is missing from the typing for TrackChangesEditing, so the code currently only works if the plug-in is explicitly cast to any:

const trackChangesEditing = editor.plugins.get( 'TrackChangesEditing' ) as any;

Is there something missing in the guide? What is it?

No response

Is there anything else you would like to add?

No response

User agent

Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:109.0) Gecko/20100101 Firefox/118.0

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Labels

    domain:integration-dxThis issue reports a problem with the developer experience when integrating CKEditor into a system.package:track-changessquad:ccxIssue to be handled by the CCX team.squad:collaborationIssue to be handled by the Collaboration team.type:docsThis issue reports a task related to documentation (e.g. an idea for a guide).

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions