-
Notifications
You must be signed in to change notification settings - Fork 3.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
chore: Remove some more uses of AnyDuringMigration #6785
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The main blocker is that this appears to contain a breaking change.
@@ -154,7 +154,7 @@ export class WorkspaceComment { | |||
* This is not valid if the comment is currently being dragged. | |||
* @internal | |||
*/ | |||
getXY(): Coordinate { | |||
getRelativeToSurfaceXY(): Coordinate { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This rename would appear to be a breaking change to the API. Is that intended? If so, please update commit message and PR title accordingly. If not, please (at most) deprecate getXY
rather than removing it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This method is @internal
, so I was under the impression we can do whatever we want with it?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd like to get @rachel-fenichel and/or @maribethb's take on that. My understanding is that there are some cases where we have previously suggested using (previously) @private
methods and now treat them as if they had been @public
for the purpose of deciding what's a breaking change.
If this method is not one we've ever suggested people use then SGTM.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this is safe--we rarely recommend devs do anything with workspace comments, and I don't remember us ever suggesting people use this. And we use the same name (getRelativeToSurfaceXY) for the same functionality in block/block_svg.
Co-authored-by: Christopher Allen <[email protected]>
Co-authored-by: Christopher Allen <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM but please check about whether the @internal
method really is sufficiently internal.
* Type guard that checks whether an IToolboxItem is an ISelectableToolboxItem. | ||
*/ | ||
export function isSelectableToolboxItem(toolboxItem: IToolboxItem): | ||
toolboxItem is ISelectableToolboxItem { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@@ -154,7 +154,7 @@ export class WorkspaceComment { | |||
* This is not valid if the comment is currently being dragged. | |||
* @internal | |||
*/ | |||
getXY(): Coordinate { | |||
getRelativeToSurfaceXY(): Coordinate { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this is safe--we rarely recommend devs do anything with workspace comments, and I don't remember us ever suggesting people use this. And we use the same name (getRelativeToSurfaceXY) for the same functionality in block/block_svg.
The basics
npm run format
andnpm run lint
The details
Resolves
Part of #5857
Proposed Changes
Removes uses of AnyDuringMigration from workspace_comment_svg.ts, toolbox.ts, field_colour.ts, field_image.ts, and workspace.ts.