-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: add feature and entity flagging into checkPermission (#1187)
* feat: add feature and entity flagging into checkPermission * fix: remove unused alpha prop - was replaces bu availability in prev breaking change * refactor: return to _entity in check functions which dont use the param
- Loading branch information
Showing
15 changed files
with
474 additions
and
240 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
12 changes: 12 additions & 0 deletions
12
packages/common/src/permissions/_internal/PermissionCheckFunction.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
import { IArcGISContext } from "../../ArcGISContext"; | ||
import { IPermissionPolicy } from "../types/IPermissionPolicy"; | ||
import { IPolicyCheck } from "../types/IPolicyCheck"; | ||
|
||
/** | ||
* Type signature for Permission Check Functions | ||
*/ | ||
export type PermissionCheckFunction = ( | ||
policy: IPermissionPolicy, | ||
context: IArcGISContext, | ||
entity?: Record<string, any> | ||
) => IPolicyCheck[]; |
40 changes: 0 additions & 40 deletions
40
packages/common/src/permissions/_internal/checkAlphaGating.ts
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
5 changes: 4 additions & 1 deletion
5
packages/common/src/permissions/_internal/checkEntityFeature.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.