Skip to content

Commit

Permalink
Class Rename
Browse files Browse the repository at this point in the history
  • Loading branch information
JPMeehan committed Nov 9, 2023
1 parent 184f59f commit 182661a
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
2 changes: 1 addition & 1 deletion src/foundry/client/apps/forms/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import "./item";
import "./journal-sheet";
import "./macro-config";
import "./measure-template";
import "./permission";
import "./ownership";
import "./playlist-config";
import "./playlist-sound-config";
import "./roll-table-config";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ declare global {
* @typeParam Options - the type of the options object
* @typeParam ConcreteDocument - the type of the Document which should be managed by this form sheet
*/
class PermissionControl<
class DocumentOwnershipConfig<
Options extends DocumentSheetOptions<ConcreteDocument>,
ConcreteDocument extends foundry.abstract.Document<any, any> = foundry.abstract.Document<any, any>,
> extends DocumentSheet<Options, ConcreteDocument> {
Expand All @@ -14,7 +14,7 @@ declare global {
* ```typescript
* foundry.utils.mergeObject(super.defaultOptions, {
* id: "permission",
* template: "templates/apps/permission.html",
* template: "templates/apps/ownership.html",
* width: 400
* })
* ```
Expand All @@ -25,10 +25,12 @@ declare global {

override getData(options?: Partial<Options> | undefined): MaybePromise<object>;

protected override _updateObject(event: Event, formData: PermissionControl.FormData): Promise<unknown>;
protected override _updateObject(event: Event, formData: DocumentOwnershipConfig.FormData): Promise<unknown>;
}

namespace PermissionControl {
class PermissionControl extends DocumentOwnershipConfig {}

namespace DocumentOwnershipConfig {
interface FormData {
[userId: string]: FormData.InputPermissionLevel;
default: FormData.InputPermissionLevel;
Expand Down

0 comments on commit 182661a

Please sign in to comment.