kendo.diagram.Path might be missing in kendo.all.d.ts

5 posts, 0 answers
  1. David
    David avatar
    6 posts
    Member since:
    Aug 2012

    Posted 29 Dec 2014 Link to this post

    I have a test index.html file that uses the following successfully:

    var path = "M10 0 L90 0 L100 25 L90 50 L10 50 L0 25 Z";
    var block = new kendo.dataviz.diagram.Path({ width: dataItem.width, height: dataItem.height, fill: { color: 'green' }, data: path });

    When I try to recode this in Typescript, kendo.dataviz.diagram.Path is undefined/undeclared.  I see no evidence of it in kendo.all.d.ts.

    This code is trying to build a group by assembling a rectangle, or a shape like the above, and some text, rather than adding shapes directly to the diagram.

    Using 2014.2.1008.commercial.  I'll look at 2014.3.1119 but I see no reference to this in the release notes.
  2. Alex Gyoshev
    Admin
    Alex Gyoshev avatar
    2500 posts

    Posted 30 Dec 2014 Link to this post

    Hello David,

    The reason for it not showing in any release is that this class is not documented. Are you passing this path on an official API method/configuration?

    Regards,
    Alex Gyoshev
    Telerik
     
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
     
  3. Kendo UI is VS 2017 Ready
  4. David
    David avatar
    6 posts
    Member since:
    Aug 2012

    Posted 30 Dec 2014 in reply to Alex Gyoshev Link to this post

    Hi Alex,

    I probably discovered it in the code rather than the documentation.  I guess we can go two ways with this.  1)Is this going to be documented and therefore become official soon?, or 2)Is there another way to accomplish what I'm trying to do?

    All I want to do is create other shapes than the default rectangle and circle by supplying SVG path data as shown.  They need to be vector graphic in nature, not image or raster in nature.

    I'd prefer not to switch to the Drawing API since Diagram provides so many additional features.

  5. David
    David avatar
    6 posts
    Member since:
    Aug 2012

    Posted 30 Dec 2014 in reply to David Link to this post

    I should have also added:

    I'm aware of the html5-diagram-sample-code app which shows how to do custom shapes.  A key difference is that I want to make mine part of a Group while the sample app handles this by adding the shape directly to the diagram.  If I use dataviz.diagram.Shape I get an error when I try to append it to the Group.  The error complains about not having a method called drawingContainer().
  6. Alex Gyoshev
    Admin
    Alex Gyoshev avatar
    2500 posts

    Posted 30 Dec 2014 Link to this post

    Hello David,

    The said functionality is not supported at this time. It appears that you have found a way to workaround it, so you can add the missing TypeScript definitions via your own file at the time being. You can suggest the path grouping functionality on UserVoice so that it is considered for implementation in future releases.

    Regards,
    Alex Gyoshev
    Telerik
     
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
     
Back to Top
Kendo UI is VS 2017 Ready