Skip to content
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

DRAFT - DO NOT MERGE - V2 Discussions #1716

Open
wants to merge 7 commits into
base: master
Choose a base branch
from

Conversation

velveetachef
Copy link
Contributor

@velveetachef velveetachef commented Nov 4, 2024

Issues:

  • 11820 - channel creator no longer owner
  • 10427 - update interfaces for V2 (channel, post, create/update channel/post)
  • 5779 - require channelId on post create (no channel create on the fly)
  • 10428 - update url for discussions v2
  • 5223 - update developer docs
  1. Description: Release of breaking changes related to Discussions V2

  2. Instructions for testing:

  3. Closes Issues: # (if appropriate)

  4. Updated meaningful TSDoc to methods including Parameters and Returns, see Documentation Guide

  5. used semantic commit messages

  6. PR title follows semantic commit format (CRITICAL if the title is not in a semantic format, the release automation will not run!)

  7. updated peerDependencies as needed. CRITICAL our automated release system can not be counted on to update peerDependencies so we must do it manually in our PRs when needed. See the updating peerDependencies section of the release instructions for more details.

@velveetachef velveetachef marked this pull request as ready for review November 4, 2024 23:57
@velveetachef velveetachef marked this pull request as draft November 5, 2024 00:10
@velveetachef velveetachef changed the title DRAFT - DO NOT MERGE DRAFT - DO NOT MERGE - V2 Discussions Nov 5, 2024
@velveetachef velveetachef force-pushed the v2-discussions-release branch from 131752a to 97ce863 Compare November 7, 2024 20:23
@velveetachef velveetachef marked this pull request as ready for review November 7, 2024 20:24
@velveetachef velveetachef marked this pull request as draft November 7, 2024 21:25
Copy link

There hasn't been any activity on this pull request in the past 3 days, so it has been marked as stale and it will be closed automatically if no further activity occurs in the next 7 days. If you want this PR to never become stale, please apply the "Draft" label.

@github-actions github-actions bot added the Stale Stale issue - update or it will be closed label Nov 12, 2024
@velveetachef velveetachef added Draft Draft PR or Issue (don't mark stale) and removed Stale Stale issue - update or it will be closed labels Nov 12, 2024
@@ -520,7 +510,7 @@ export interface ICreateChannelPost extends IPostOptions, ICreateChannel {}
* @extends {IHubRequestOptions}
*/
export interface ICreatePostParams extends IDiscussionsRequestOptions {
data: ICreatePost | ICreateChannelPost;
data: ICreatePost;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This will require changes to the post-editor component as V2 does not support creating channels on the fly while creating a post; a channelId is now required to be sent through. Need designs from Sam.

* @hidden
*/
channelAclDefinition?: IChannelAclPermissionDefinition[];
channelAclDefinition: IChannelAclPermissionDefinition[];
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This will have impact on the Discussion Board workspace UI where we create channels. We'll now need to build ACL rules there vs selecting groups/access/allowAnonymous

access?: SharingAccess;
allowAnonymous?: boolean;
groups?: string[];
channelAclDefinition?: IChannelAclPermissionDefinition[];
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Similar point as above, impacts Discussion Board participation pane where we create/edit channels. Need ACL UI versus legacy access/groups/allowAnonymous

IUpdateChannelPermissions,
Partial<IWithAuthor> {}
extends IUpdateChannelSettings,
IUpdateChannelPermissions {}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This relates to the legacy V1 code creating channels on the fly in private content discussions. The desire was that the channel owner should be the same as the group owner, so the client would override/update the channel owner to mirror that of the group that was configured for the channel. We'll need to kill off that owner reassignment code when we strip out the ability to create channels on the fly.

blockWords?: string[];
defaultPostStatus?: PostStatus;
metadata?: IChannelMetadata;
name?: string;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

New interface to account for delta between the name being required when creating a channel, but optional (can be undefined) when updating due to nature of HTTP patch.

@@ -57,7 +57,6 @@ export class ChannelPermission {
private isChannelAclEmpty: boolean;
private existingChannel: IChannel;
private permissionsByCategory: PermissionsByAclCategoryMap;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Merely related to no longer considering channel creator as the channel "owner".

@velveetachef velveetachef force-pushed the v2-discussions-release branch from e1f3768 to 2095df3 Compare November 25, 2024 23:14
@velveetachef velveetachef marked this pull request as ready for review November 25, 2024 23:15
@velveetachef velveetachef marked this pull request as draft November 26, 2024 15:57
@velveetachef velveetachef marked this pull request as ready for review November 26, 2024 17:52
@@ -71,7 +71,7 @@ export function apiRequest<T>(
// TODO: we _want_ to use getHubApiUrl(),
// but have to deal w/ the fact that this package overwrites IHubRequestOptions
host: options.hubApiUrl || "https://hub.arcgis.com",
path: "/api/discussions/v1",
path: "/api/discussions/v2",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can/should this pull from hubApiEndpoints?

@velveetachef velveetachef force-pushed the v2-discussions-release branch from 5be937d to 38ff477 Compare December 5, 2024 01:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Draft Draft PR or Issue (don't mark stale)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants