Skip to content

Conversation

fred441a
Copy link

@fred441a fred441a commented Feb 2, 2022

hi, i am aware of the other pull request by @lifejuggler. But seeing as how that is over a year old i thought i would just contribute again. i have updated some of @lifejugglers code to be able to merge into the newest master branch, and added a bit of a patch solution to id's

		if (slideItemObj.options != undefined) {
			if (slideItemObj.options.sId != undefined) {
				if (IDs.indexOf(slideItemObj.options.sId) > -1) {
					throw "ID is already in use, object / shape id cannot be the same for multiple objects / shapes";
				} else {
					IDs.push(slideItemObj.options.sId);
				}

			} else {
				if (IDs.indexOf(idx + 2) > -1) {
					throw "an sID used matched an automatically generated ID try using a higher number";
				} else {
					IDs.push(idx + 2);
				}

			}
		}

this at least throws an error if you have colliding id's, however i was wondering you you though it would be smarter to just automatically increment over already taken ids or if functions should return an automatically generated id to the user for them to use.

i also added an anchor enum that works at least for rectangular shapes. and added connectors to the shapes demo, like you asked.

i can also add connectors to other objects like tables or media, but i don't know if that is even somthing that we want?

should the user need to calculate their own position of of the connector arrows, or do we want this functionality built into the library? i can add this feature for squares at least.

i am very willing to help out with development of this feature if you just tell my what you think is best.

@Hoogkamer
Copy link
Contributor

This is a great and very important feature to have! Will it be available soon?

@gitbrent
Copy link
Owner

Thanks @fred441a - can you provide sample usage code?

@fred441a
Copy link
Author

i have added the connected lines for shapes functionallity to the shapes demo

@f3ve
Copy link

f3ve commented Feb 24, 2022

Would love to see this feature added soon. Anything I can do to help with this process?

@gitbrent gitbrent added this to the 4.0.0 milestone Feb 25, 2022
@Michael-Reich
Copy link

Why isn't that implemented?

@roberrrt-s
Copy link

Aware i'm necrobumping but I would really appreciate this functionality :)

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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants