@ieeesa-npm/groups 0.15.6 → 0.15.7

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.
@@ -186,7 +186,19 @@ export declare class AddUserRosterComponent implements OnInit, OnDestroy {
186
186
  */
187
187
  isAllOtherControlsValid(): boolean;
188
188
  /**
189
- * Enables or disables submit button.
189
+ * Single source of truth for the Save button enabled/disabled state.
190
+ *
191
+ * Combines both inputs that gate the form so every callback (form change,
192
+ * role selection, org selection) computes the same result — mirroring the
193
+ * edit-user-roles flow:
194
+ * 1. Base validity via GroupsService.isSubmitButtonDisabled, which accounts
195
+ * for the reactive form status AND (for SYSTEM_USER) the selected roles,
196
+ * since roles live in `selectedUserRoles`, not the form.
197
+ * 2. For INDIVIDUAL only: the `representingOrg` control stays INVALID because
198
+ * its value is held in `selectedOrganizations` (a multiselect autocomplete),
199
+ * not the control. So also enable when every other control is valid and at
200
+ * least one organization is selected, even though the form status is
201
+ * INVALID.
190
202
  * @memberof AddUserRosterComponent
191
203
  */
192
204
  updateSubmitButtonStatus(): void;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ieeesa-npm/groups",
3
- "version": "0.15.6",
3
+ "version": "0.15.7",
4
4
  "peerDependencies": {
5
5
  "@angular/common": "^16.1.0",
6
6
  "@angular/core": "^16.1.0"