@pnp/cli-microsoft365 10.0.0-beta.58f28f9 → 10.0.0-beta.66db729

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (25) hide show
  1. package/allCommands.json +1 -1
  2. package/allCommandsFull.json +1 -1
  3. package/dist/m365/entra/commands/group/{group-user-add.js → group-member-add.js} +18 -18
  4. package/dist/m365/entra/commands/group/{group-user-list.js → group-member-list.js} +17 -17
  5. package/dist/m365/entra/commands/group/{group-user-set.js → group-member-set.js} +19 -19
  6. package/dist/m365/entra/commands.js +3 -3
  7. package/dist/m365/spfx/commands/project/project-doctor/{doctor-1.20.0-rc.1.js → doctor-1.20.0.js} +4 -2
  8. package/dist/m365/spfx/commands/project/project-doctor/rules/FN002021_DEVDEP_rushstack_eslint_config.js +10 -0
  9. package/dist/m365/spfx/commands/project/project-doctor.js +1 -1
  10. package/dist/m365/spfx/commands/project/project-upgrade/{upgrade-1.20.0-rc.1.js → upgrade-1.20.0.js} +28 -26
  11. package/dist/m365/spfx/commands/project/project-upgrade.js +13 -15
  12. package/dist/m365/spfx/commands/spfx-doctor.js +1 -1
  13. package/dist/m365/spo/commands/page/page-remove.js +37 -16
  14. package/dist/m365/spo/commands/site/site-sharingpermission-set.js +68 -0
  15. package/dist/m365/spo/commands.js +1 -0
  16. package/dist/utils/urlUtil.js +8 -0
  17. package/docs/docs/cmd/entra/group/group-member-add.mdx +62 -0
  18. package/docs/docs/cmd/entra/group/{group-user-list.mdx → group-member-list.mdx} +14 -14
  19. package/docs/docs/cmd/entra/group/group-member-set.mdx +62 -0
  20. package/docs/docs/cmd/spfx/project/project-upgrade.mdx +1 -1
  21. package/docs/docs/cmd/spo/page/page-remove.mdx +30 -12
  22. package/docs/docs/cmd/spo/site/site-sharingpermission-set.mdx +58 -0
  23. package/package.json +1 -1
  24. package/docs/docs/cmd/entra/group/group-user-add.mdx +0 -62
  25. package/docs/docs/cmd/entra/group/group-user-set.mdx +0 -62
@@ -3,34 +3,34 @@ var __classPrivateFieldGet = (this && this.__classPrivateFieldGet) || function (
3
3
  if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
4
4
  return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
5
5
  };
6
- var _EntraGroupUserAddCommand_instances, _EntraGroupUserAddCommand_initTelemetry, _EntraGroupUserAddCommand_initOptions, _EntraGroupUserAddCommand_initValidators, _EntraGroupUserAddCommand_initOptionSets, _EntraGroupUserAddCommand_initTypes;
6
+ var _EntraGroupMemberAddCommand_instances, _EntraGroupMemberAddCommand_initTelemetry, _EntraGroupMemberAddCommand_initOptions, _EntraGroupMemberAddCommand_initValidators, _EntraGroupMemberAddCommand_initOptionSets, _EntraGroupMemberAddCommand_initTypes;
7
7
  import request from '../../../../request.js';
8
8
  import { entraGroup } from '../../../../utils/entraGroup.js';
9
9
  import { entraUser } from '../../../../utils/entraUser.js';
10
10
  import { validation } from '../../../../utils/validation.js';
11
11
  import GraphCommand from '../../../base/GraphCommand.js';
12
12
  import commands from '../../commands.js';
13
- class EntraGroupUserAddCommand extends GraphCommand {
13
+ class EntraGroupMemberAddCommand extends GraphCommand {
14
14
  get name() {
15
- return commands.GROUP_USER_ADD;
15
+ return commands.GROUP_MEMBER_ADD;
16
16
  }
17
17
  get description() {
18
- return 'Adds a user to a Microsoft Entra ID group';
18
+ return 'Adds a member to a Microsoft Entra ID group';
19
19
  }
20
20
  constructor() {
21
21
  super();
22
- _EntraGroupUserAddCommand_instances.add(this);
22
+ _EntraGroupMemberAddCommand_instances.add(this);
23
23
  this.roleValues = ['Owner', 'Member'];
24
- __classPrivateFieldGet(this, _EntraGroupUserAddCommand_instances, "m", _EntraGroupUserAddCommand_initTelemetry).call(this);
25
- __classPrivateFieldGet(this, _EntraGroupUserAddCommand_instances, "m", _EntraGroupUserAddCommand_initOptions).call(this);
26
- __classPrivateFieldGet(this, _EntraGroupUserAddCommand_instances, "m", _EntraGroupUserAddCommand_initValidators).call(this);
27
- __classPrivateFieldGet(this, _EntraGroupUserAddCommand_instances, "m", _EntraGroupUserAddCommand_initOptionSets).call(this);
28
- __classPrivateFieldGet(this, _EntraGroupUserAddCommand_instances, "m", _EntraGroupUserAddCommand_initTypes).call(this);
24
+ __classPrivateFieldGet(this, _EntraGroupMemberAddCommand_instances, "m", _EntraGroupMemberAddCommand_initTelemetry).call(this);
25
+ __classPrivateFieldGet(this, _EntraGroupMemberAddCommand_instances, "m", _EntraGroupMemberAddCommand_initOptions).call(this);
26
+ __classPrivateFieldGet(this, _EntraGroupMemberAddCommand_instances, "m", _EntraGroupMemberAddCommand_initValidators).call(this);
27
+ __classPrivateFieldGet(this, _EntraGroupMemberAddCommand_instances, "m", _EntraGroupMemberAddCommand_initOptionSets).call(this);
28
+ __classPrivateFieldGet(this, _EntraGroupMemberAddCommand_instances, "m", _EntraGroupMemberAddCommand_initTypes).call(this);
29
29
  }
30
30
  async commandAction(logger, args) {
31
31
  try {
32
32
  if (this.verbose) {
33
- await logger.logToStderr(`Adding user(s) ${args.options.ids || args.options.userNames} to group ${args.options.groupId || args.options.groupDisplayName}...`);
33
+ await logger.logToStderr(`Adding member(s) ${args.options.ids || args.options.userNames} to group ${args.options.groupId || args.options.groupDisplayName}...`);
34
34
  }
35
35
  const groupId = await this.getGroupId(logger, args.options);
36
36
  const userIds = await this.getUserIds(logger, args.options);
@@ -91,7 +91,7 @@ class EntraGroupUserAddCommand extends GraphCommand {
91
91
  return entraUser.getUserIdsByUpns(options.userNames.split(',').map(u => u.trim()));
92
92
  }
93
93
  }
94
- _EntraGroupUserAddCommand_instances = new WeakSet(), _EntraGroupUserAddCommand_initTelemetry = function _EntraGroupUserAddCommand_initTelemetry() {
94
+ _EntraGroupMemberAddCommand_instances = new WeakSet(), _EntraGroupMemberAddCommand_initTelemetry = function _EntraGroupMemberAddCommand_initTelemetry() {
95
95
  this.telemetry.push((args) => {
96
96
  Object.assign(this.telemetryProperties, {
97
97
  groupId: typeof args.options.groupId !== 'undefined',
@@ -100,7 +100,7 @@ _EntraGroupUserAddCommand_instances = new WeakSet(), _EntraGroupUserAddCommand_i
100
100
  userNames: typeof args.options.userNames !== 'undefined'
101
101
  });
102
102
  });
103
- }, _EntraGroupUserAddCommand_initOptions = function _EntraGroupUserAddCommand_initOptions() {
103
+ }, _EntraGroupMemberAddCommand_initOptions = function _EntraGroupMemberAddCommand_initOptions() {
104
104
  this.options.unshift({
105
105
  option: '-i, --groupId [groupId]'
106
106
  }, {
@@ -113,7 +113,7 @@ _EntraGroupUserAddCommand_instances = new WeakSet(), _EntraGroupUserAddCommand_i
113
113
  option: '-r, --role <role>',
114
114
  autocomplete: this.roleValues
115
115
  });
116
- }, _EntraGroupUserAddCommand_initValidators = function _EntraGroupUserAddCommand_initValidators() {
116
+ }, _EntraGroupMemberAddCommand_initValidators = function _EntraGroupMemberAddCommand_initValidators() {
117
117
  this.validators.push(async (args) => {
118
118
  if (args.options.groupId && !validation.isValidGuid(args.options.groupId)) {
119
119
  return `${args.options.groupId} is not a valid GUID for option groupId.`;
@@ -135,10 +135,10 @@ _EntraGroupUserAddCommand_instances = new WeakSet(), _EntraGroupUserAddCommand_i
135
135
  }
136
136
  return true;
137
137
  });
138
- }, _EntraGroupUserAddCommand_initOptionSets = function _EntraGroupUserAddCommand_initOptionSets() {
138
+ }, _EntraGroupMemberAddCommand_initOptionSets = function _EntraGroupMemberAddCommand_initOptionSets() {
139
139
  this.optionSets.push({ options: ['groupId', 'groupDisplayName'] }, { options: ['ids', 'userNames'] });
140
- }, _EntraGroupUserAddCommand_initTypes = function _EntraGroupUserAddCommand_initTypes() {
140
+ }, _EntraGroupMemberAddCommand_initTypes = function _EntraGroupMemberAddCommand_initTypes() {
141
141
  this.types.string.push('groupId', 'groupDisplayName', 'ids', 'userNames', 'role');
142
142
  };
143
- export default new EntraGroupUserAddCommand();
144
- //# sourceMappingURL=group-user-add.js.map
143
+ export default new EntraGroupMemberAddCommand();
144
+ //# sourceMappingURL=group-member-add.js.map
@@ -3,19 +3,19 @@ var __classPrivateFieldGet = (this && this.__classPrivateFieldGet) || function (
3
3
  if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
4
4
  return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
5
5
  };
6
- var _EntraGroupUserListCommand_instances, _EntraGroupUserListCommand_initTelemetry, _EntraGroupUserListCommand_initOptions, _EntraGroupUserListCommand_initOptionSets, _EntraGroupUserListCommand_initValidators;
6
+ var _EntraGroupMemberListCommand_instances, _EntraGroupMemberListCommand_initTelemetry, _EntraGroupMemberListCommand_initOptions, _EntraGroupMemberListCommand_initOptionSets, _EntraGroupMemberListCommand_initValidators;
7
7
  import { entraGroup } from '../../../../utils/entraGroup.js';
8
8
  import { odata } from '../../../../utils/odata.js';
9
9
  import { validation } from '../../../../utils/validation.js';
10
10
  import GraphCommand from '../../../base/GraphCommand.js';
11
11
  import commands from '../../commands.js';
12
12
  import aadCommands from '../../aadCommands.js';
13
- class EntraGroupUserListCommand extends GraphCommand {
13
+ class EntraGroupMemberListCommand extends GraphCommand {
14
14
  get name() {
15
- return commands.GROUP_USER_LIST;
15
+ return commands.GROUP_MEMBER_LIST;
16
16
  }
17
17
  get description() {
18
- return 'Lists users of a specific Entra group';
18
+ return 'Lists members of a specific Entra group';
19
19
  }
20
20
  alias() {
21
21
  return [aadCommands.GROUP_USER_LIST];
@@ -25,14 +25,14 @@ class EntraGroupUserListCommand extends GraphCommand {
25
25
  }
26
26
  constructor() {
27
27
  super();
28
- _EntraGroupUserListCommand_instances.add(this);
29
- __classPrivateFieldGet(this, _EntraGroupUserListCommand_instances, "m", _EntraGroupUserListCommand_initTelemetry).call(this);
30
- __classPrivateFieldGet(this, _EntraGroupUserListCommand_instances, "m", _EntraGroupUserListCommand_initOptions).call(this);
31
- __classPrivateFieldGet(this, _EntraGroupUserListCommand_instances, "m", _EntraGroupUserListCommand_initOptionSets).call(this);
32
- __classPrivateFieldGet(this, _EntraGroupUserListCommand_instances, "m", _EntraGroupUserListCommand_initValidators).call(this);
28
+ _EntraGroupMemberListCommand_instances.add(this);
29
+ __classPrivateFieldGet(this, _EntraGroupMemberListCommand_instances, "m", _EntraGroupMemberListCommand_initTelemetry).call(this);
30
+ __classPrivateFieldGet(this, _EntraGroupMemberListCommand_instances, "m", _EntraGroupMemberListCommand_initOptions).call(this);
31
+ __classPrivateFieldGet(this, _EntraGroupMemberListCommand_instances, "m", _EntraGroupMemberListCommand_initOptionSets).call(this);
32
+ __classPrivateFieldGet(this, _EntraGroupMemberListCommand_instances, "m", _EntraGroupMemberListCommand_initValidators).call(this);
33
33
  }
34
34
  async commandAction(logger, args) {
35
- await this.showDeprecationWarning(logger, aadCommands.GROUP_USER_LIST, commands.GROUP_USER_LIST);
35
+ await this.showDeprecationWarning(logger, aadCommands.GROUP_USER_LIST, commands.GROUP_MEMBER_LIST);
36
36
  try {
37
37
  const groupId = await this.getGroupId(args.options, logger);
38
38
  const users = [];
@@ -86,7 +86,7 @@ class EntraGroupUserListCommand extends GraphCommand {
86
86
  });
87
87
  const expandParam = fieldExpand.length > 0 ? `&$expand=${fieldExpand}` : '';
88
88
  const selectParam = allSelectProperties.filter(item => !item.includes('/'));
89
- const endpoint = `${this.resource}/v1.0/groups/${groupId}/${role}/microsoft.graph.user?$select=${selectParam}${expandParam}`;
89
+ const endpoint = `${this.resource}/v1.0/groups/${groupId}/${role}?$select=${selectParam}${expandParam}`;
90
90
  let users = [];
91
91
  if (filter) {
92
92
  // While using the filter, we need to specify the ConsistencyLevel header.
@@ -107,7 +107,7 @@ class EntraGroupUserListCommand extends GraphCommand {
107
107
  return users;
108
108
  }
109
109
  }
110
- _EntraGroupUserListCommand_instances = new WeakSet(), _EntraGroupUserListCommand_initTelemetry = function _EntraGroupUserListCommand_initTelemetry() {
110
+ _EntraGroupMemberListCommand_instances = new WeakSet(), _EntraGroupMemberListCommand_initTelemetry = function _EntraGroupMemberListCommand_initTelemetry() {
111
111
  this.telemetry.push((args) => {
112
112
  Object.assign(this.telemetryProperties, {
113
113
  groupId: typeof args.options.groupId !== 'undefined',
@@ -117,7 +117,7 @@ _EntraGroupUserListCommand_instances = new WeakSet(), _EntraGroupUserListCommand
117
117
  filter: typeof args.options.filter !== 'undefined'
118
118
  });
119
119
  });
120
- }, _EntraGroupUserListCommand_initOptions = function _EntraGroupUserListCommand_initOptions() {
120
+ }, _EntraGroupMemberListCommand_initOptions = function _EntraGroupMemberListCommand_initOptions() {
121
121
  this.options.unshift({
122
122
  option: "-i, --groupId [groupId]"
123
123
  }, {
@@ -130,11 +130,11 @@ _EntraGroupUserListCommand_instances = new WeakSet(), _EntraGroupUserListCommand
130
130
  }, {
131
131
  option: "-f, --filter [filter]"
132
132
  });
133
- }, _EntraGroupUserListCommand_initOptionSets = function _EntraGroupUserListCommand_initOptionSets() {
133
+ }, _EntraGroupMemberListCommand_initOptionSets = function _EntraGroupMemberListCommand_initOptionSets() {
134
134
  this.optionSets.push({
135
135
  options: ['groupId', 'groupName']
136
136
  });
137
- }, _EntraGroupUserListCommand_initValidators = function _EntraGroupUserListCommand_initValidators() {
137
+ }, _EntraGroupMemberListCommand_initValidators = function _EntraGroupMemberListCommand_initValidators() {
138
138
  this.validators.push(async (args) => {
139
139
  if (args.options.groupId && !validation.isValidGuid(args.options.groupId)) {
140
140
  return `${args.options.groupId} is not a valid GUID`;
@@ -147,5 +147,5 @@ _EntraGroupUserListCommand_instances = new WeakSet(), _EntraGroupUserListCommand
147
147
  return true;
148
148
  });
149
149
  };
150
- export default new EntraGroupUserListCommand();
151
- //# sourceMappingURL=group-user-list.js.map
150
+ export default new EntraGroupMemberListCommand();
151
+ //# sourceMappingURL=group-member-list.js.map
@@ -3,34 +3,34 @@ var __classPrivateFieldGet = (this && this.__classPrivateFieldGet) || function (
3
3
  if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
4
4
  return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
5
5
  };
6
- var _EntraGroupUserSetCommand_instances, _EntraGroupUserSetCommand_initTelemetry, _EntraGroupUserSetCommand_initOptions, _EntraGroupUserSetCommand_initValidators, _EntraGroupUserSetCommand_initOptionSets, _EntraGroupUserSetCommand_initTypes;
6
+ var _EntraGroupMemberSetCommand_instances, _EntraGroupMemberSetCommand_initTelemetry, _EntraGroupMemberSetCommand_initOptions, _EntraGroupMemberSetCommand_initValidators, _EntraGroupMemberSetCommand_initOptionSets, _EntraGroupMemberSetCommand_initTypes;
7
7
  import request from '../../../../request.js';
8
8
  import { entraGroup } from '../../../../utils/entraGroup.js';
9
9
  import { entraUser } from '../../../../utils/entraUser.js';
10
10
  import { validation } from '../../../../utils/validation.js';
11
11
  import GraphCommand from '../../../base/GraphCommand.js';
12
12
  import commands from '../../commands.js';
13
- class EntraGroupUserSetCommand extends GraphCommand {
13
+ class EntraGroupMemberSetCommand extends GraphCommand {
14
14
  get name() {
15
- return commands.GROUP_USER_SET;
15
+ return commands.GROUP_MEMBER_SET;
16
16
  }
17
17
  get description() {
18
- return 'Updates role of users in a Microsoft Entra ID group';
18
+ return 'Updates the role of members in a Microsoft Entra ID group';
19
19
  }
20
20
  constructor() {
21
21
  super();
22
- _EntraGroupUserSetCommand_instances.add(this);
22
+ _EntraGroupMemberSetCommand_instances.add(this);
23
23
  this.roleValues = ['Owner', 'Member'];
24
- __classPrivateFieldGet(this, _EntraGroupUserSetCommand_instances, "m", _EntraGroupUserSetCommand_initTelemetry).call(this);
25
- __classPrivateFieldGet(this, _EntraGroupUserSetCommand_instances, "m", _EntraGroupUserSetCommand_initOptions).call(this);
26
- __classPrivateFieldGet(this, _EntraGroupUserSetCommand_instances, "m", _EntraGroupUserSetCommand_initValidators).call(this);
27
- __classPrivateFieldGet(this, _EntraGroupUserSetCommand_instances, "m", _EntraGroupUserSetCommand_initOptionSets).call(this);
28
- __classPrivateFieldGet(this, _EntraGroupUserSetCommand_instances, "m", _EntraGroupUserSetCommand_initTypes).call(this);
24
+ __classPrivateFieldGet(this, _EntraGroupMemberSetCommand_instances, "m", _EntraGroupMemberSetCommand_initTelemetry).call(this);
25
+ __classPrivateFieldGet(this, _EntraGroupMemberSetCommand_instances, "m", _EntraGroupMemberSetCommand_initOptions).call(this);
26
+ __classPrivateFieldGet(this, _EntraGroupMemberSetCommand_instances, "m", _EntraGroupMemberSetCommand_initValidators).call(this);
27
+ __classPrivateFieldGet(this, _EntraGroupMemberSetCommand_instances, "m", _EntraGroupMemberSetCommand_initOptionSets).call(this);
28
+ __classPrivateFieldGet(this, _EntraGroupMemberSetCommand_instances, "m", _EntraGroupMemberSetCommand_initTypes).call(this);
29
29
  }
30
30
  async commandAction(logger, args) {
31
31
  try {
32
32
  if (this.verbose) {
33
- await logger.logToStderr(`Adding user(s) ${args.options.ids || args.options.userNames} to group ${args.options.groupId || args.options.groupDisplayName}...`);
33
+ await logger.logToStderr(`Adding member(s) ${args.options.ids || args.options.userNames} to role ${args.options.role} of group ${args.options.groupId || args.options.groupDisplayName}...`);
34
34
  }
35
35
  const groupId = await this.getGroupId(logger, args.options);
36
36
  const userIds = await this.getUserIds(logger, args.options);
@@ -66,7 +66,7 @@ class EntraGroupUserSetCommand extends GraphCommand {
66
66
  const userIdsToRemove = [];
67
67
  const currentRole = options.role === 'Member' ? 'owners' : 'members';
68
68
  if (this.verbose) {
69
- await logger.logToStderr(`Removing users from the old role '${currentRole}'.`);
69
+ await logger.logToStderr(`Removing members from the old role '${currentRole}'.`);
70
70
  }
71
71
  for (let i = 0; i < userIds.length; i += 20) {
72
72
  const userIdsBatch = userIds.slice(i, i + 20);
@@ -153,7 +153,7 @@ class EntraGroupUserSetCommand extends GraphCommand {
153
153
  return requestOptions;
154
154
  }
155
155
  }
156
- _EntraGroupUserSetCommand_instances = new WeakSet(), _EntraGroupUserSetCommand_initTelemetry = function _EntraGroupUserSetCommand_initTelemetry() {
156
+ _EntraGroupMemberSetCommand_instances = new WeakSet(), _EntraGroupMemberSetCommand_initTelemetry = function _EntraGroupMemberSetCommand_initTelemetry() {
157
157
  this.telemetry.push((args) => {
158
158
  Object.assign(this.telemetryProperties, {
159
159
  groupId: typeof args.options.groupId !== 'undefined',
@@ -162,7 +162,7 @@ _EntraGroupUserSetCommand_instances = new WeakSet(), _EntraGroupUserSetCommand_i
162
162
  userNames: typeof args.options.userNames !== 'undefined'
163
163
  });
164
164
  });
165
- }, _EntraGroupUserSetCommand_initOptions = function _EntraGroupUserSetCommand_initOptions() {
165
+ }, _EntraGroupMemberSetCommand_initOptions = function _EntraGroupMemberSetCommand_initOptions() {
166
166
  this.options.unshift({
167
167
  option: '-i, --groupId [groupId]'
168
168
  }, {
@@ -175,7 +175,7 @@ _EntraGroupUserSetCommand_instances = new WeakSet(), _EntraGroupUserSetCommand_i
175
175
  option: '-r, --role <role>',
176
176
  autocomplete: this.roleValues
177
177
  });
178
- }, _EntraGroupUserSetCommand_initValidators = function _EntraGroupUserSetCommand_initValidators() {
178
+ }, _EntraGroupMemberSetCommand_initValidators = function _EntraGroupMemberSetCommand_initValidators() {
179
179
  this.validators.push(async (args) => {
180
180
  if (args.options.groupId && !validation.isValidGuid(args.options.groupId)) {
181
181
  return `${args.options.groupId} is not a valid GUID for option groupId.`;
@@ -197,10 +197,10 @@ _EntraGroupUserSetCommand_instances = new WeakSet(), _EntraGroupUserSetCommand_i
197
197
  }
198
198
  return true;
199
199
  });
200
- }, _EntraGroupUserSetCommand_initOptionSets = function _EntraGroupUserSetCommand_initOptionSets() {
200
+ }, _EntraGroupMemberSetCommand_initOptionSets = function _EntraGroupMemberSetCommand_initOptionSets() {
201
201
  this.optionSets.push({ options: ['groupId', 'groupDisplayName'] }, { options: ['ids', 'userNames'] });
202
- }, _EntraGroupUserSetCommand_initTypes = function _EntraGroupUserSetCommand_initTypes() {
202
+ }, _EntraGroupMemberSetCommand_initTypes = function _EntraGroupMemberSetCommand_initTypes() {
203
203
  this.types.string.push('groupId', 'groupDisplayName', 'ids', 'userNames', 'role');
204
204
  };
205
- export default new EntraGroupUserSetCommand();
206
- //# sourceMappingURL=group-user-set.js.map
205
+ export default new EntraGroupMemberSetCommand();
206
+ //# sourceMappingURL=group-member-set.js.map
@@ -41,9 +41,9 @@ export default {
41
41
  GROUP_LIST: `${prefix} group list`,
42
42
  GROUP_REMOVE: `${prefix} group remove`,
43
43
  GROUP_SET: `${prefix} group set`,
44
- GROUP_USER_ADD: `${prefix} group user add`,
45
- GROUP_USER_LIST: `${prefix} group user list`,
46
- GROUP_USER_SET: `${prefix} group user set`,
44
+ GROUP_MEMBER_ADD: `${prefix} group member add`,
45
+ GROUP_MEMBER_LIST: `${prefix} group member list`,
46
+ GROUP_MEMBER_SET: `${prefix} group member set`,
47
47
  GROUPSETTING_ADD: `${prefix} groupsetting add`,
48
48
  GROUPSETTING_GET: `${prefix} groupsetting get`,
49
49
  GROUPSETTING_LIST: `${prefix} groupsetting list`,
@@ -1,3 +1,4 @@
1
+ import { FN002021_DEVDEP_rushstack_eslint_config } from '../project-upgrade/rules/FN002021_DEVDEP_rushstack_eslint_config.js';
1
2
  import { FN001008_DEP_react } from './rules/FN001008_DEP_react.js';
2
3
  import { FN001009_DEP_react_dom } from './rules/FN001009_DEP_react_dom.js';
3
4
  import { FN001035_DEP_fluentui_react } from './rules/FN001035_DEP_fluentui_react.js';
@@ -19,7 +20,8 @@ export default [
19
20
  new FN002015_DEVDEP_types_react('17'),
20
21
  new FN002016_DEVDEP_types_react_dom('17'),
21
22
  new FN002019_DEVDEP_microsoft_rush_stack_compiler(['4.7']),
23
+ new FN002021_DEVDEP_rushstack_eslint_config('4.0.1'),
22
24
  new FN021001_PKG_spfx_deps_versions_match_project_version(false),
23
- new FN021013_PKG_spfx_devdeps_match_version('1.20.1')
25
+ new FN021013_PKG_spfx_devdeps_match_version('1.20.2')
24
26
  ];
25
- //# sourceMappingURL=doctor-1.20.0-rc.1.js.map
27
+ //# sourceMappingURL=doctor-1.20.0.js.map
@@ -0,0 +1,10 @@
1
+ import { DependencyRule } from './DependencyRule.js';
2
+ export class FN002021_DEVDEP_rushstack_eslint_config extends DependencyRule {
3
+ constructor(supportedRange) {
4
+ super('@rushstack/eslint-config', supportedRange, true);
5
+ }
6
+ get id() {
7
+ return 'FN002021';
8
+ }
9
+ }
10
+ //# sourceMappingURL=FN002021_DEVDEP_rushstack_eslint_config.js.map
@@ -71,7 +71,7 @@ class SpfxProjectDoctorCommand extends BaseProjectCommand {
71
71
  '1.18.1',
72
72
  '1.18.2',
73
73
  '1.19.0',
74
- '1.20.0-rc.1'
74
+ '1.20.0'
75
75
  ];
76
76
  __classPrivateFieldGet(this, _SpfxProjectDoctorCommand_instances, "m", _SpfxProjectDoctorCommand_initTelemetry).call(this);
77
77
  __classPrivateFieldGet(this, _SpfxProjectDoctorCommand_instances, "m", _SpfxProjectDoctorCommand_initOptions).call(this);
@@ -20,38 +20,40 @@ import { FN001032_DEP_microsoft_sp_page_context } from './rules/FN001032_DEP_mic
20
20
  import { FN001034_DEP_microsoft_sp_adaptive_card_extension_base } from './rules/FN001034_DEP_microsoft_sp_adaptive_card_extension_base.js';
21
21
  import { FN002001_DEVDEP_microsoft_sp_build_web } from './rules/FN002001_DEVDEP_microsoft_sp_build_web.js';
22
22
  import { FN002002_DEVDEP_microsoft_sp_module_interfaces } from './rules/FN002002_DEVDEP_microsoft_sp_module_interfaces.js';
23
+ import { FN002021_DEVDEP_rushstack_eslint_config } from './rules/FN002021_DEVDEP_rushstack_eslint_config.js';
23
24
  import { FN002022_DEVDEP_microsoft_eslint_plugin_spfx } from './rules/FN002022_DEVDEP_microsoft_eslint_plugin_spfx.js';
24
25
  import { FN002023_DEVDEP_microsoft_eslint_config_spfx } from './rules/FN002023_DEVDEP_microsoft_eslint_config_spfx.js';
25
26
  import { FN002024_DEVDEP_eslint } from './rules/FN002024_DEVDEP_eslint.js';
26
27
  import { FN010001_YORC_version } from './rules/FN010001_YORC_version.js';
27
28
  import { FN010010_YORC_sdkVersions_teams_js } from './rules/FN010010_YORC_sdkVersions_teams_js.js';
28
29
  export default [
29
- new FN001001_DEP_microsoft_sp_core_library('1.20.0-rc.1'),
30
- new FN001002_DEP_microsoft_sp_lodash_subset('1.20.0-rc.1'),
31
- new FN001003_DEP_microsoft_sp_office_ui_fabric_core('1.20.0-rc.1'),
32
- new FN001004_DEP_microsoft_sp_webpart_base('1.20.0-rc.1'),
33
- new FN001011_DEP_microsoft_sp_dialog('1.20.0-rc.1'),
34
- new FN001012_DEP_microsoft_sp_application_base('1.20.0-rc.1'),
35
- new FN001014_DEP_microsoft_sp_listview_extensibility('1.20.0-rc.1'),
36
- new FN001021_DEP_microsoft_sp_property_pane('1.20.0-rc.1'),
37
- new FN001023_DEP_microsoft_sp_component_base('1.20.0-rc.1'),
38
- new FN001024_DEP_microsoft_sp_diagnostics('1.20.0-rc.1'),
39
- new FN001025_DEP_microsoft_sp_dynamic_data('1.20.0-rc.1'),
40
- new FN001026_DEP_microsoft_sp_extension_base('1.20.0-rc.1'),
41
- new FN001027_DEP_microsoft_sp_http('1.20.0-rc.1'),
42
- new FN001028_DEP_microsoft_sp_list_subscription('1.20.0-rc.1'),
43
- new FN001029_DEP_microsoft_sp_loader('1.20.0-rc.1'),
44
- new FN001030_DEP_microsoft_sp_module_interfaces('1.20.0-rc.1'),
45
- new FN001031_DEP_microsoft_sp_odata_types('1.20.0-rc.1'),
46
- new FN001032_DEP_microsoft_sp_page_context('1.20.0-rc.1'),
47
- new FN001013_DEP_microsoft_decorators('1.20.0-rc.1'),
48
- new FN001034_DEP_microsoft_sp_adaptive_card_extension_base('1.20.0-rc.1'),
49
- new FN002001_DEVDEP_microsoft_sp_build_web('1.20.1'),
50
- new FN002002_DEVDEP_microsoft_sp_module_interfaces('1.20.1'),
30
+ new FN001001_DEP_microsoft_sp_core_library('1.20.0'),
31
+ new FN001002_DEP_microsoft_sp_lodash_subset('1.20.0'),
32
+ new FN001003_DEP_microsoft_sp_office_ui_fabric_core('1.20.0'),
33
+ new FN001004_DEP_microsoft_sp_webpart_base('1.20.0'),
34
+ new FN001011_DEP_microsoft_sp_dialog('1.20.0'),
35
+ new FN001012_DEP_microsoft_sp_application_base('1.20.0'),
36
+ new FN001014_DEP_microsoft_sp_listview_extensibility('1.20.0'),
37
+ new FN001021_DEP_microsoft_sp_property_pane('1.20.0'),
38
+ new FN001023_DEP_microsoft_sp_component_base('1.20.0'),
39
+ new FN001024_DEP_microsoft_sp_diagnostics('1.20.0'),
40
+ new FN001025_DEP_microsoft_sp_dynamic_data('1.20.0'),
41
+ new FN001026_DEP_microsoft_sp_extension_base('1.20.0'),
42
+ new FN001027_DEP_microsoft_sp_http('1.20.0'),
43
+ new FN001028_DEP_microsoft_sp_list_subscription('1.20.0'),
44
+ new FN001029_DEP_microsoft_sp_loader('1.20.0'),
45
+ new FN001030_DEP_microsoft_sp_module_interfaces('1.20.0'),
46
+ new FN001031_DEP_microsoft_sp_odata_types('1.20.0'),
47
+ new FN001032_DEP_microsoft_sp_page_context('1.20.0'),
48
+ new FN001013_DEP_microsoft_decorators('1.20.0'),
49
+ new FN001034_DEP_microsoft_sp_adaptive_card_extension_base('1.20.0'),
50
+ new FN002001_DEVDEP_microsoft_sp_build_web('1.20.2'),
51
+ new FN002002_DEVDEP_microsoft_sp_module_interfaces('1.20.2'),
52
+ new FN002021_DEVDEP_rushstack_eslint_config('4.0.1'),
51
53
  new FN002024_DEVDEP_eslint('8.57.0'),
52
- new FN002022_DEVDEP_microsoft_eslint_plugin_spfx('1.20.1'),
53
- new FN002023_DEVDEP_microsoft_eslint_config_spfx('1.20.1'),
54
- new FN010001_YORC_version('1.20.0-rc.1'),
54
+ new FN002022_DEVDEP_microsoft_eslint_plugin_spfx('1.20.2'),
55
+ new FN002023_DEVDEP_microsoft_eslint_config_spfx('1.20.2'),
56
+ new FN010001_YORC_version('1.20.0'),
55
57
  new FN010010_YORC_sdkVersions_teams_js('2.24.0')
56
58
  ];
57
- //# sourceMappingURL=upgrade-1.20.0-rc.1.js.map
59
+ //# sourceMappingURL=upgrade-1.20.0.js.map
@@ -7,8 +7,6 @@ var _SpfxProjectUpgradeCommand_instances, _a, _SpfxProjectUpgradeCommand_initTel
7
7
  import fs from 'fs';
8
8
  import os from 'os';
9
9
  import path from 'path';
10
- // uncomment to support upgrading to preview releases
11
- import { prerelease } from 'semver';
12
10
  import { CommandError } from '../../../../Command.js';
13
11
  import { fsUtil } from '../../../../utils/fsUtil.js';
14
12
  import { packageManager } from '../../../../utils/packageManager.js';
@@ -75,7 +73,7 @@ class SpfxProjectUpgradeCommand extends BaseProjectCommand {
75
73
  '1.18.1',
76
74
  '1.18.2',
77
75
  '1.19.0',
78
- '1.20.0-rc.1'
76
+ '1.20.0'
79
77
  ];
80
78
  __classPrivateFieldGet(this, _SpfxProjectUpgradeCommand_instances, "m", _SpfxProjectUpgradeCommand_initTelemetry).call(this);
81
79
  __classPrivateFieldGet(this, _SpfxProjectUpgradeCommand_instances, "m", _SpfxProjectUpgradeCommand_initOptions).call(this);
@@ -88,15 +86,15 @@ class SpfxProjectUpgradeCommand extends BaseProjectCommand {
88
86
  }
89
87
  this.toVersion = args.options.toVersion ? args.options.toVersion : this.supportedVersions[this.supportedVersions.length - 1];
90
88
  // uncomment to support upgrading to preview releases
91
- if (!args.options.toVersion &&
92
- !args.options.preview &&
93
- prerelease(this.toVersion)) {
94
- // no version and no preview specified while the current version to
95
- // upgrade to is a prerelease so let's grab the first non-preview version
96
- // since we're supporting only one preview version, it's sufficient for
97
- // us to take second to last version
98
- this.toVersion = this.supportedVersions[this.supportedVersions.length - 2];
99
- }
89
+ // if (!args.options.toVersion &&
90
+ // !args.options.preview &&
91
+ // prerelease(this.toVersion)) {
92
+ // // no version and no preview specified while the current version to
93
+ // // upgrade to is a prerelease so let's grab the first non-preview version
94
+ // // since we're supporting only one preview version, it's sufficient for
95
+ // // us to take second to last version
96
+ // this.toVersion = this.supportedVersions[this.supportedVersions.length - 2];
97
+ // }
100
98
  this.packageManager = args.options.packageManager || 'npm';
101
99
  this.shell = args.options.shell || 'bash';
102
100
  if (this.supportedVersions.indexOf(this.toVersion) < 0) {
@@ -485,9 +483,9 @@ _a = SpfxProjectUpgradeCommand, _SpfxProjectUpgradeCommand_instances = new WeakS
485
483
  preview: args.options.preview
486
484
  });
487
485
  // uncomment to support upgrading to preview releases
488
- if (prerelease(this.telemetryProperties.toVersion) && !args.options.preview) {
489
- this.telemetryProperties.toVersion = this.supportedVersions[this.supportedVersions.length - 2];
490
- }
486
+ // if (prerelease(this.telemetryProperties.toVersion) && !args.options.preview) {
487
+ // this.telemetryProperties.toVersion = this.supportedVersions[this.supportedVersions.length - 2];
488
+ // }
491
489
  });
492
490
  }, _SpfxProjectUpgradeCommand_initOptions = function _SpfxProjectUpgradeCommand_initOptions() {
493
491
  this.options.unshift({
@@ -576,7 +576,7 @@ class SpfxDoctorCommand extends BaseProjectCommand {
576
576
  fix: 'npm i -g yo@5'
577
577
  }
578
578
  },
579
- '1.20.0-rc.1': {
579
+ '1.20.0': {
580
580
  gulpCli: {
581
581
  range: '^1 || ^2 || ^3',
582
582
  fix: 'npm i -g gulp-cli@3'
@@ -3,10 +3,10 @@ var __classPrivateFieldGet = (this && this.__classPrivateFieldGet) || function (
3
3
  if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
4
4
  return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
5
5
  };
6
- var _SpoPageRemoveCommand_instances, _SpoPageRemoveCommand_initOptions, _SpoPageRemoveCommand_initValidators;
6
+ var _SpoPageRemoveCommand_instances, _SpoPageRemoveCommand_initTelemetry, _SpoPageRemoveCommand_initOptions, _SpoPageRemoveCommand_initValidators, _SpoPageRemoveCommand_initTypes;
7
7
  import { cli } from '../../../../cli/cli.js';
8
8
  import request from '../../../../request.js';
9
- import { spo } from '../../../../utils/spo.js';
9
+ import { formatting } from '../../../../utils/formatting.js';
10
10
  import { urlUtil } from '../../../../utils/urlUtil.js';
11
11
  import { validation } from '../../../../utils/validation.js';
12
12
  import SpoCommand from '../../../base/SpoCommand.js';
@@ -21,15 +21,17 @@ class SpoPageRemoveCommand extends SpoCommand {
21
21
  constructor() {
22
22
  super();
23
23
  _SpoPageRemoveCommand_instances.add(this);
24
+ __classPrivateFieldGet(this, _SpoPageRemoveCommand_instances, "m", _SpoPageRemoveCommand_initTelemetry).call(this);
24
25
  __classPrivateFieldGet(this, _SpoPageRemoveCommand_instances, "m", _SpoPageRemoveCommand_initOptions).call(this);
25
26
  __classPrivateFieldGet(this, _SpoPageRemoveCommand_instances, "m", _SpoPageRemoveCommand_initValidators).call(this);
27
+ __classPrivateFieldGet(this, _SpoPageRemoveCommand_instances, "m", _SpoPageRemoveCommand_initTypes).call(this);
26
28
  }
27
29
  async commandAction(logger, args) {
28
30
  if (args.options.force) {
29
31
  await this.removePage(logger, args);
30
32
  }
31
33
  else {
32
- const result = await cli.promptForConfirmation({ message: `Are you sure you want to remove the page '${args.options.name}'?` });
34
+ const result = await cli.promptForConfirmation({ message: `Are you sure you want to remove page '${args.options.name}'?` });
33
35
  if (result) {
34
36
  await this.removePage(logger, args);
35
37
  }
@@ -37,44 +39,63 @@ class SpoPageRemoveCommand extends SpoCommand {
37
39
  }
38
40
  async removePage(logger, args) {
39
41
  try {
40
- let requestDigest = '';
41
- let pageName = args.options.name;
42
- const reqDigest = await spo.getRequestDigest(args.options.webUrl);
43
- requestDigest = reqDigest.FormDigestValue;
44
- if (!pageName.endsWith('.aspx')) {
42
+ // Remove leading slashes from the page name (page can be nested in folders)
43
+ let pageName = urlUtil.removeLeadingSlashes(args.options.name);
44
+ if (!pageName.toLowerCase().endsWith('.aspx')) {
45
45
  pageName += '.aspx';
46
46
  }
47
47
  if (this.verbose) {
48
48
  await logger.logToStderr(`Removing page ${pageName}...`);
49
49
  }
50
+ const filePath = `${urlUtil.getServerRelativeSiteUrl(args.options.webUrl)}/SitePages/${pageName}`;
50
51
  const requestOptions = {
51
- url: `${args.options
52
- .webUrl}/_api/web/GetFileByServerRelativePath(DecodedUrl='${urlUtil.getServerRelativeSiteUrl(args.options.webUrl)}/sitepages/${pageName}')`,
52
+ url: `${args.options.webUrl}/_api/web/GetFileByServerRelativePath(DecodedUrl='${formatting.encodeQueryParameter(filePath)}')`,
53
53
  headers: {
54
- 'X-RequestDigest': requestDigest,
55
- 'X-HTTP-Method': 'DELETE',
56
- 'content-type': 'application/json;odata=nometadata',
57
54
  accept: 'application/json;odata=nometadata'
58
55
  },
59
56
  responseType: 'json'
60
57
  };
61
- await request.post(requestOptions);
58
+ if (args.options.bypassSharedLock) {
59
+ requestOptions.headers.Prefer = 'bypass-shared-lock';
60
+ }
61
+ if (args.options.recycle) {
62
+ requestOptions.url += '/Recycle';
63
+ await request.post(requestOptions);
64
+ }
65
+ else {
66
+ await request.delete(requestOptions);
67
+ }
62
68
  }
63
69
  catch (err) {
64
70
  this.handleRejectedODataJsonPromise(err);
65
71
  }
66
72
  }
67
73
  }
68
- _SpoPageRemoveCommand_instances = new WeakSet(), _SpoPageRemoveCommand_initOptions = function _SpoPageRemoveCommand_initOptions() {
74
+ _SpoPageRemoveCommand_instances = new WeakSet(), _SpoPageRemoveCommand_initTelemetry = function _SpoPageRemoveCommand_initTelemetry() {
75
+ this.telemetry.push((args) => {
76
+ Object.assign(this.telemetryProperties, {
77
+ force: !!args.options.force,
78
+ recycle: !!args.options.recycle,
79
+ bypassSharedLock: !!args.options.bypassSharedLock
80
+ });
81
+ });
82
+ }, _SpoPageRemoveCommand_initOptions = function _SpoPageRemoveCommand_initOptions() {
69
83
  this.options.unshift({
84
+ option: '-u, --webUrl <webUrl>'
85
+ }, {
70
86
  option: '-n, --name <name>'
71
87
  }, {
72
- option: '-u, --webUrl <webUrl>'
88
+ option: '--recycle'
89
+ }, {
90
+ option: '--bypassSharedLock'
73
91
  }, {
74
92
  option: '-f, --force'
75
93
  });
76
94
  }, _SpoPageRemoveCommand_initValidators = function _SpoPageRemoveCommand_initValidators() {
77
95
  this.validators.push(async (args) => validation.isValidSharePointUrl(args.options.webUrl));
96
+ }, _SpoPageRemoveCommand_initTypes = function _SpoPageRemoveCommand_initTypes() {
97
+ this.types.string.push('name', 'webUrl');
98
+ this.types.boolean.push('force', 'bypassSharedLock', 'recycle');
78
99
  };
79
100
  export default new SpoPageRemoveCommand();
80
101
  //# sourceMappingURL=page-remove.js.map