diff --git a/Projects/Governance/Icons/pool-weight-vote.png b/Projects/Governance/Icons/pool-weight-vote.png new file mode 100644 index 000000000..f13a9dc29 Binary files /dev/null and b/Projects/Governance/Icons/pool-weight-vote.png differ diff --git a/Projects/Governance/Icons/pool.png b/Projects/Governance/Icons/pool.png new file mode 100644 index 000000000..14bfad9d7 Binary files /dev/null and b/Projects/Governance/Icons/pool.png differ diff --git a/Projects/Governance/Icons/pools.png b/Projects/Governance/Icons/pools.png new file mode 100644 index 000000000..d9e46d9a4 Binary files /dev/null and b/Projects/Governance/Icons/pools.png differ diff --git a/Projects/Governance/Icons/referrer.png b/Projects/Governance/Icons/referrer.png new file mode 100644 index 000000000..c42733847 Binary files /dev/null and b/Projects/Governance/Icons/referrer.png differ diff --git a/Projects/Governance/Icons/tokens-switch.png b/Projects/Governance/Icons/tokens-switch.png new file mode 100644 index 000000000..d573c891d Binary files /dev/null and b/Projects/Governance/Icons/tokens-switch.png differ diff --git a/Projects/Governance/Schemas/App-Schema/time-vote.json b/Projects/Governance/Schemas/App-Schema/Referrer.json similarity index 77% rename from Projects/Governance/Schemas/App-Schema/time-vote.json rename to Projects/Governance/Schemas/App-Schema/Referrer.json index 45984f061..39fb7fc32 100644 --- a/Projects/Governance/Schemas/App-Schema/time-vote.json +++ b/Projects/Governance/Schemas/App-Schema/Referrer.json @@ -1,5 +1,5 @@ { - "type": "Time Vote", + "type": "Referrer", "menuItems": [ { "action": "Configure", @@ -19,7 +19,6 @@ } ], "title": [ - "Reference Parent Find Node Type->User Profile", "Use Reference Parent" ], "editors": { @@ -31,11 +30,11 @@ "addLeftIcons": true, "level": 2, "attachingRules": { - "compatibleTypes": "->Civic Contributions->" + "compatibleTypes": "->User Profile->" }, "referencingRules": { - "compatibleTypes": "->Contributed Time->" + "compatibleTypes": "->User Profile->" }, - "propertyNameAtParent": "timeVotes", - "icon": "dogecoin" + "propertyNameAtParent": "referrer", + "icon": "github-api" } \ No newline at end of file diff --git a/Projects/Governance/Schemas/App-Schema/asset-claim-vote.json b/Projects/Governance/Schemas/App-Schema/asset-claim-vote.json new file mode 100644 index 000000000..97fd65724 --- /dev/null +++ b/Projects/Governance/Schemas/App-Schema/asset-claim-vote.json @@ -0,0 +1,41 @@ +{ + "type": "Asset Claim Vote", + "menuItems": [ + { + "action": "Configure", + "actionFunction": "uiObject.configEditor.activate", + "label": "Configure", + "iconPathOn": "configuration", + "iconPathOff": "configuration" + }, + { + "action": "Delete UI Object", + "askConfirmation": true, + "confirmationLabel": "Confirm to Delete", + "label": "Delete", + "iconPathOn": "delete-entity", + "iconPathOff": "delete-entity", + "actionFunction": "payload.executeAction" + } + ], + "title": [ + "Reference Parent Find In Parents Node Type->User Profile", + "Use Reference Parent" + ], + "editors": { + "config": true + }, + "initialValues": { + "config": "{\n \"description\": \"\"\n}" + }, + "addLeftIcons": true, + "level": 2, + "attachingRules": { + "compatibleTypes": "->Votes Switch->" + }, + "referencingRules": { + "compatibleTypes": "->Asset Contribution Claim->" + }, + "propertyNameAtParent": "assetClaimVotes", + "icon": "EN" +} \ No newline at end of file diff --git a/Projects/Governance/Schemas/App-Schema/asset-class.json b/Projects/Governance/Schemas/App-Schema/asset-class.json index 938beef44..b81dc371e 100644 --- a/Projects/Governance/Schemas/App-Schema/asset-class.json +++ b/Projects/Governance/Schemas/App-Schema/asset-class.json @@ -42,7 +42,7 @@ "compatibleTypes": "->Assets->Asset Class->" }, "referencingRules": { - "compatibleTypes": "->Team->Ranking Position->" + "compatibleTypes": "->Position Class->Position->" }, "propertyNameAtParent": "assetClasses", "childrenNodesProperties": [ diff --git a/Projects/Governance/Schemas/App-Schema/contributed-asset.json b/Projects/Governance/Schemas/App-Schema/asset-contribution-claim.json similarity index 86% rename from Projects/Governance/Schemas/App-Schema/contributed-asset.json rename to Projects/Governance/Schemas/App-Schema/asset-contribution-claim.json index f75d6d45c..536d946db 100644 --- a/Projects/Governance/Schemas/App-Schema/contributed-asset.json +++ b/Projects/Governance/Schemas/App-Schema/asset-contribution-claim.json @@ -1,5 +1,5 @@ { - "type": "Contributed Asset", + "type": "Asset Contribution Claim", "menuItems": [ { "action": "Configure", @@ -31,11 +31,11 @@ "addLeftIcons": true, "level": 2, "attachingRules": { - "compatibleTypes": "->Software Contributions->" + "compatibleTypes": "->Asset Contributions Folder->" }, "referencingRules": { "compatibleTypes": "->Asset->" }, - "propertyNameAtParent": "contributedAssets", + "propertyNameAtParent": "assetContributionClaims", "icon": "tron" } \ No newline at end of file diff --git a/Projects/Governance/Schemas/App-Schema/marketing-contributions.json b/Projects/Governance/Schemas/App-Schema/asset-contributions-folder.json similarity index 67% rename from Projects/Governance/Schemas/App-Schema/marketing-contributions.json rename to Projects/Governance/Schemas/App-Schema/asset-contributions-folder.json index af618182b..ef08212b5 100644 --- a/Projects/Governance/Schemas/App-Schema/marketing-contributions.json +++ b/Projects/Governance/Schemas/App-Schema/asset-contributions-folder.json @@ -1,5 +1,5 @@ { - "type": "Marketing Contributions", + "type": "Asset Contributions Folder", "menuItems": [ { "action": "Configure", @@ -11,14 +11,14 @@ { "action": "Add UI Object", "actionFunction": "payload.executeAction", - "label": "Add Marketing Contributions", - "relatedUiObject": "Marketing Contributions" + "label": "Add Asset Contributions Folder", + "relatedUiObject": "Asset Contributions Folder" }, { "action": "Add UI Object", "actionFunction": "payload.executeAction", - "label": "Add Contributed Asset", - "relatedUiObject": "Contributed Asset" + "label": "Add Asset Contribution Claim", + "relatedUiObject": "Asset Contribution Claim" }, { "action": "Delete UI Object", @@ -39,20 +39,20 @@ "addLeftIcons": true, "level": 2, "attachingRules": { - "compatibleTypes": "->User Profile->Marketing Contributions->" + "compatibleTypes": "->Contribution Claims->Asset Contributions Folder->" }, - "propertyNameAtParent": "marketingContributions", + "propertyNameAtParent": "assetContributionsFolder", "childrenNodesProperties": [ { - "name": "marketingContributions", + "name": "assetContributionsFolder", "type": "array", - "childType": "Marketing Contributions", + "childType": "Asset Contributions Folder", "autoAdd": false }, { - "name": "contributedAssets", + "name": "assetContributionClaims", "type": "array", - "childType": "Contributed Asset", + "childType": "Asset Contribution Claim", "autoAdd": false } ], diff --git a/Projects/Governance/Schemas/App-Schema/asset-vote.json b/Projects/Governance/Schemas/App-Schema/asset-weight-vote.json similarity index 89% rename from Projects/Governance/Schemas/App-Schema/asset-vote.json rename to Projects/Governance/Schemas/App-Schema/asset-weight-vote.json index b6c4275ca..bc254bfb3 100644 --- a/Projects/Governance/Schemas/App-Schema/asset-vote.json +++ b/Projects/Governance/Schemas/App-Schema/asset-weight-vote.json @@ -1,5 +1,5 @@ { - "type": "Asset Vote", + "type": "Asset Weight Vote", "menuItems": [ { "action": "Configure", @@ -33,11 +33,11 @@ "addLeftIcons": true, "level": 2, "attachingRules": { - "compatibleTypes": "->Civic Contributions->" + "compatibleTypes": "->Votes Switch->" }, "referencingRules": { "compatibleTypes": "->Asset Class->Asset->" }, - "propertyNameAtParent": "assetVotes", + "propertyNameAtParent": "assetWeightVotes", "icon": "EN" } \ No newline at end of file diff --git a/Projects/Governance/Schemas/App-Schema/asset.json b/Projects/Governance/Schemas/App-Schema/asset.json index 43e6cf0fc..5209c2fb0 100644 --- a/Projects/Governance/Schemas/App-Schema/asset.json +++ b/Projects/Governance/Schemas/App-Schema/asset.json @@ -34,16 +34,13 @@ "config": true }, "initialValues": { - "config": "{\n \"description\": \"\", \"relativeWeight\": 0 \n}" + "config": "{\n \"description\": \"\" \n}" }, "addLeftIcons": true, "level": 2, "attachingRules": { "compatibleTypes": "->Asset Class->Asset->" }, - "referencingRules": { - "compatibleTypes": "->Team->Ranking Position->" - }, "propertyNameAtParent": "assets", "childrenNodesProperties": [ { diff --git a/Projects/Governance/Schemas/App-Schema/assets.json b/Projects/Governance/Schemas/App-Schema/assets.json index 1f986969d..899e739a1 100644 --- a/Projects/Governance/Schemas/App-Schema/assets.json +++ b/Projects/Governance/Schemas/App-Schema/assets.json @@ -25,10 +25,7 @@ ], "isHierarchyHead": true, "addLeftIcons": true, - "level": 1, - "attachingRules": { - "compatibleTypes": "->Superalgos Release->" - }, + "level": 0, "childrenNodesProperties": [ { "name": "assetClasses", diff --git a/Projects/Governance/Schemas/App-Schema/civic-contributions.json b/Projects/Governance/Schemas/App-Schema/civic-contributions.json deleted file mode 100644 index e73c1cdda..000000000 --- a/Projects/Governance/Schemas/App-Schema/civic-contributions.json +++ /dev/null @@ -1,108 +0,0 @@ -{ - "type": "Civic Contributions", - "menuItems": [ - { - "action": "Configure", - "actionFunction": "uiObject.configEditor.activate", - "label": "Configure", - "iconPathOn": "configuration", - "iconPathOff": "configuration" - }, - { - "action": "Add UI Object", - "actionFunction": "payload.executeAction", - "label": "Add Civic Contributions", - "relatedUiObject": "Civic Contributions" - }, - { - "action": "Add UI Object", - "actionFunction": "payload.executeAction", - "label": "Add Ranking Vote", - "relatedUiObject": "Ranking Vote" - }, - { - "action": "Add UI Object", - "actionFunction": "payload.executeAction", - "label": "Add Asset Vote", - "relatedUiObject": "Asset Vote" - }, - { - "action": "Add UI Object", - "actionFunction": "payload.executeAction", - "label": "Add Feature Vote", - "relatedUiObject": "Feature Vote" - }, - { - "action": "Add UI Object", - "actionFunction": "payload.executeAction", - "label": "Add Time Vote", - "relatedUiObject": "Time Vote" - }, - { - "action": "Add UI Object", - "actionFunction": "payload.executeAction", - "label": "Add User Vote", - "relatedUiObject": "User Vote" - }, - { - "action": "Delete UI Object", - "askConfirmation": true, - "confirmationLabel": "Confirm to Delete", - "label": "Delete", - "iconPathOn": "delete-entity", - "iconPathOff": "delete-entity", - "actionFunction": "payload.executeAction" - } - ], - "editors": { - "config": true - }, - "initialValues": { - "config": "{\n \"description\": \"\"\n}" - }, - "addLeftIcons": true, - "level": 2, - "attachingRules": { - "compatibleTypes": "->User Profile->Civic Contributions->" - }, - "propertyNameAtParent": "civicContributions", - "childrenNodesProperties": [ - { - "name": "civicContributions", - "type": "array", - "childType": "Civic Contributions", - "autoAdd": false - }, - { - "name": "assetVotes", - "type": "array", - "childType": "Asset Vote", - "autoAdd": false - }, - { - "name": "featureVotes", - "type": "array", - "childType": "Feature Vote", - "autoAdd": false - }, - { - "name": "timeVotes", - "type": "array", - "childType": "Time Vote", - "autoAdd": false - }, - { - "name": "rankingVotes", - "type": "array", - "childType": "Ranking Vote", - "autoAdd": false - }, - { - "name": "userVotes", - "type": "array", - "childType": "User Vote", - "autoAdd": false - } - ], - "icon": "bitcoin" -} \ No newline at end of file diff --git a/Projects/Governance/Schemas/App-Schema/contributed-youtube-video.json b/Projects/Governance/Schemas/App-Schema/contributed-youtube-video.json index 089b52a8c..fe07c5c9c 100644 --- a/Projects/Governance/Schemas/App-Schema/contributed-youtube-video.json +++ b/Projects/Governance/Schemas/App-Schema/contributed-youtube-video.json @@ -35,7 +35,7 @@ "attachingRules": { "compatibleTypes": "->Assets->Asset->" }, - "propertyNameAtParent": "softwareContributions", + "propertyNameAtParent": "assetContributionsFolder", "childrenNodesProperties": [ { "name": "assetClass", diff --git a/Projects/Governance/Schemas/App-Schema/contribution-claims.json b/Projects/Governance/Schemas/App-Schema/contribution-claims.json new file mode 100644 index 000000000..93b8bcf82 --- /dev/null +++ b/Projects/Governance/Schemas/App-Schema/contribution-claims.json @@ -0,0 +1,72 @@ +{ + "type": "Contribution Claims", + "menuItems": [ + { + "action": "Configure", + "actionFunction": "uiObject.configEditor.activate", + "label": "Configure", + "iconPathOn": "configuration", + "iconPathOff": "configuration" + }, + { + "action": "Add UI Object", + "label": "Add Asset Contributions Folder", + "relatedUiObject": "Asset Contributions Folder", + "actionFunction": "payload.executeAction" + }, + { + "action": "Add UI Object", + "actionFunction": "payload.executeAction", + "label": "Add Feature Contributions Folder", + "relatedUiObject": "Feature Contributions Folder" + }, + { + "action": "Add UI Object", + "actionFunction": "payload.executeAction", + "label": "Add Position Contributions Folder", + "relatedUiObject": "Position Contributions Folder" + }, + { + "action": "Delete UI Object", + "askConfirmation": true, + "confirmationLabel": "Confirm to Delete", + "label": "Delete", + "iconPathOn": "delete-entity", + "iconPathOff": "delete-entity", + "actionFunction": "payload.executeAction" + } + ], + "editors": { + "config": true + }, + "initialValues": { + "config": "{\n\"codeName\": \"\"\n}" + }, + "attachingRules": { + "compatibleTypes": "->User Profile->" + }, + "addLeftIcons": true, + "level": 1, + "propertyNameAtParent": "contributionClaims", + "childrenNodesProperties": [ + { + "name": "assetContributionsFolder", + "type": "array", + "childType": "Asset Contributions Folder", + "autoAdd": false + }, + { + "name": "featureContributionsFolder", + "type": "array", + "childType": "Feature Contributions Folder", + "autoAdd": false + }, + { + "name": "positionContributionsFolder", + "type": "array", + "childType": "Position Contributions Folder", + "autoAdd": false + } + ], + "icon": "bitcoin" +} \ No newline at end of file diff --git a/Projects/Governance/Schemas/App-Schema/feature-claim-vote.json b/Projects/Governance/Schemas/App-Schema/feature-claim-vote.json new file mode 100644 index 000000000..a5123d218 --- /dev/null +++ b/Projects/Governance/Schemas/App-Schema/feature-claim-vote.json @@ -0,0 +1,41 @@ +{ + "type": "Feature Claim Vote", + "menuItems": [ + { + "action": "Configure", + "actionFunction": "uiObject.configEditor.activate", + "label": "Configure", + "iconPathOn": "configuration", + "iconPathOff": "configuration" + }, + { + "action": "Delete UI Object", + "askConfirmation": true, + "confirmationLabel": "Confirm to Delete", + "label": "Delete", + "iconPathOn": "delete-entity", + "iconPathOff": "delete-entity", + "actionFunction": "payload.executeAction" + } + ], + "title": [ + "Reference Parent Find In Parents Node Type->User Profile", + "Use Reference Parent" + ], + "editors": { + "config": true + }, + "initialValues": { + "config": "{\n \"description\": \"\"\n}" + }, + "addLeftIcons": true, + "level": 2, + "attachingRules": { + "compatibleTypes": "->Votes Switch->" + }, + "referencingRules": { + "compatibleTypes": "->Feature Contribution Claim->" + }, + "propertyNameAtParent": "featureClaimVotes", + "icon": "github-api" +} \ No newline at end of file diff --git a/Projects/Governance/Schemas/App-Schema/feature-class.json b/Projects/Governance/Schemas/App-Schema/feature-class.json index 61f5ca07d..109110a9d 100644 --- a/Projects/Governance/Schemas/App-Schema/feature-class.json +++ b/Projects/Governance/Schemas/App-Schema/feature-class.json @@ -42,7 +42,7 @@ "compatibleTypes": "->Features->Feature Class->" }, "referencingRules": { - "compatibleTypes": "->Team->Ranking Position->" + "compatibleTypes": "->Position Class->Position->" }, "propertyNameAtParent": "featureClasses", "childrenNodesProperties": [ diff --git a/Projects/Governance/Schemas/App-Schema/feature-contribution-claim.json b/Projects/Governance/Schemas/App-Schema/feature-contribution-claim.json new file mode 100644 index 000000000..2d8769949 --- /dev/null +++ b/Projects/Governance/Schemas/App-Schema/feature-contribution-claim.json @@ -0,0 +1,41 @@ +{ + "type": "Feature Contribution Claim", + "menuItems": [ + { + "action": "Configure", + "actionFunction": "uiObject.configEditor.activate", + "label": "Configure", + "iconPathOn": "configuration", + "iconPathOff": "configuration" + }, + { + "action": "Delete UI Object", + "askConfirmation": true, + "confirmationLabel": "Confirm to Delete", + "label": "Delete", + "iconPathOn": "delete-entity", + "iconPathOff": "delete-entity", + "actionFunction": "payload.executeAction" + } + ], + "title": [ + "Use Reference Parent", + "Use Reference Parent Parent" + ], + "editors": { + "config": true + }, + "initialValues": { + "config": "{\n \"description\": \"\"\n}" + }, + "addLeftIcons": true, + "level": 2, + "attachingRules": { + "compatibleTypes": "->Feature Contributions Folder->" + }, + "referencingRules": { + "compatibleTypes": "->Feature->" + }, + "propertyNameAtParent": "featureContributionClaims", + "icon": "tron" +} \ No newline at end of file diff --git a/Projects/Governance/Schemas/App-Schema/community-contributions.json b/Projects/Governance/Schemas/App-Schema/feature-contributions-folder.json similarity index 66% rename from Projects/Governance/Schemas/App-Schema/community-contributions.json rename to Projects/Governance/Schemas/App-Schema/feature-contributions-folder.json index b34bfa6f0..04c3c5037 100644 --- a/Projects/Governance/Schemas/App-Schema/community-contributions.json +++ b/Projects/Governance/Schemas/App-Schema/feature-contributions-folder.json @@ -1,5 +1,5 @@ { - "type": "Community Contributions", + "type": "Feature Contributions Folder", "menuItems": [ { "action": "Configure", @@ -11,14 +11,14 @@ { "action": "Add UI Object", "actionFunction": "payload.executeAction", - "label": "Add Community Contributions", - "relatedUiObject": "Community Contributions" + "label": "Add Feature Contributions Folder", + "relatedUiObject": "Feature Contributions Folder" }, { "action": "Add UI Object", "actionFunction": "payload.executeAction", - "label": "Add Contributed Asset", - "relatedUiObject": "Contributed Asset" + "label": "Add Feature Contribution Claim", + "relatedUiObject": "Feature Contribution Claim" }, { "action": "Delete UI Object", @@ -39,20 +39,20 @@ "addLeftIcons": true, "level": 2, "attachingRules": { - "compatibleTypes": "->User Profile->Community Contributions->" + "compatibleTypes": "->Contribution Claims->Feature Contributions Folder->" }, - "propertyNameAtParent": "communityContributions", + "propertyNameAtParent": "featureContributionsFolder", "childrenNodesProperties": [ { - "name": "communityContributions", + "name": "featureContributionsFolder", "type": "array", - "childType": "Community Contributions", + "childType": "Feature Contributions Folder", "autoAdd": false }, { - "name": "contributedAssets", + "name": "featureContributionClaims", "type": "array", - "childType": "Contributed Asset", + "childType": "Feature Contribution Claim", "autoAdd": false } ], diff --git a/Projects/Governance/Schemas/App-Schema/feature-vote.json b/Projects/Governance/Schemas/App-Schema/feature-weight-vote.json similarity index 88% rename from Projects/Governance/Schemas/App-Schema/feature-vote.json rename to Projects/Governance/Schemas/App-Schema/feature-weight-vote.json index 72fc22580..a919051b5 100644 --- a/Projects/Governance/Schemas/App-Schema/feature-vote.json +++ b/Projects/Governance/Schemas/App-Schema/feature-weight-vote.json @@ -1,5 +1,5 @@ { - "type": "Feature Vote", + "type": "Feature Weight Vote", "menuItems": [ { "action": "Configure", @@ -32,11 +32,11 @@ "addLeftIcons": true, "level": 2, "attachingRules": { - "compatibleTypes": "->Civic Contributions->" + "compatibleTypes": "->Votes Switch->" }, "referencingRules": { "compatibleTypes": "->Feature Class->Feature->" }, - "propertyNameAtParent": "featureVotes", + "propertyNameAtParent": "featureWeightVotes", "icon": "github-api" } \ No newline at end of file diff --git a/Projects/Governance/Schemas/App-Schema/feature.json b/Projects/Governance/Schemas/App-Schema/feature.json index ad2f8a448..f2e4fdf4e 100644 --- a/Projects/Governance/Schemas/App-Schema/feature.json +++ b/Projects/Governance/Schemas/App-Schema/feature.json @@ -34,16 +34,13 @@ "config": true }, "initialValues": { - "config": "{\n \"description\": \"\", \"relativeWeight\": 0 \n}" + "config": "{\n \"description\": \"\" \n}" }, "addLeftIcons": true, "level": 2, "attachingRules": { "compatibleTypes": "->Feature Class->Feature->" }, - "referencingRules": { - "compatibleTypes": "->Team->Ranking Position->" - }, "propertyNameAtParent": "features", "childrenNodesProperties": [ { diff --git a/Projects/Governance/Schemas/App-Schema/features.json b/Projects/Governance/Schemas/App-Schema/features.json index 4c627c4db..fe2ae1110 100644 --- a/Projects/Governance/Schemas/App-Schema/features.json +++ b/Projects/Governance/Schemas/App-Schema/features.json @@ -25,10 +25,7 @@ ], "isHierarchyHead": true, "addLeftIcons": true, - "level": 1, - "attachingRules": { - "compatibleTypes": "->Superalgos Release->" - }, + "level": 0, "childrenNodesProperties": [ { "name": "featureClasses", diff --git a/Projects/Governance/Schemas/App-Schema/governance-project.json b/Projects/Governance/Schemas/App-Schema/governance-project.json index eb838db37..cb0f41e9c 100644 --- a/Projects/Governance/Schemas/App-Schema/governance-project.json +++ b/Projects/Governance/Schemas/App-Schema/governance-project.json @@ -1,6 +1,12 @@ { "type": "Governance Project", "menuItems": [ + { + "action": "Add UI Object", + "label": "Add Pools", + "relatedUiObject": "Pools", + "actionFunction": "payload.executeAction" + }, { "action": "Add UI Object", "label": "Add Assets", @@ -15,8 +21,8 @@ }, { "action": "Add UI Object", - "label": "Add Ranking", - "relatedUiObject": "Ranking", + "label": "Add Positions", + "relatedUiObject": "Positions", "actionFunction": "payload.executeAction" }, { diff --git a/Projects/Governance/Schemas/App-Schema/ranking-position.json b/Projects/Governance/Schemas/App-Schema/pool-class.json similarity index 70% rename from Projects/Governance/Schemas/App-Schema/ranking-position.json rename to Projects/Governance/Schemas/App-Schema/pool-class.json index 7c77d314a..84e4ff7b1 100644 --- a/Projects/Governance/Schemas/App-Schema/ranking-position.json +++ b/Projects/Governance/Schemas/App-Schema/pool-class.json @@ -1,5 +1,5 @@ { - "type": "Ranking Position", + "type": "Tokens Switch", "menuItems": [ { "action": "Configure", @@ -11,14 +11,14 @@ { "action": "Add UI Object", "actionFunction": "payload.executeAction", - "label": "Add Ranking Position", - "relatedUiObject": "Ranking Position" + "label": "Add Tokens Switch", + "relatedUiObject": "Tokens Switch" }, { "action": "Add UI Object", "actionFunction": "payload.executeAction", - "label": "Add Team", - "relatedUiObject": "Team" + "label": "Add Pool", + "relatedUiObject": "Pool" }, { "action": "Delete UI Object", @@ -39,22 +39,24 @@ "addLeftIcons": true, "level": 2, "attachingRules": { - "compatibleTypes": "->Ranking->Ranking Position->Team->" + "compatibleTypes": "->Pools->Tokens Switch->" }, - "propertyNameAtParent": "rankingPositions", + "referencingRules": { + "compatibleTypes": "->Position Class->Position->" + }, + "propertyNameAtParent": "tokensSwitches", "childrenNodesProperties": [ { - "name": "rankingPositions", + "name": "tokensSwitches", "type": "array", - "childType": "Ranking Position", + "childType": "Tokens Switch", "autoAdd": false }, { - "name": "teams", + "name": "pools", "type": "array", - "childType": "Team", + "childType": "Pool", "autoAdd": false } - ], - "icon": "bitfinex" + ] } \ No newline at end of file diff --git a/Projects/Governance/Schemas/App-Schema/pool-weight-vote.json b/Projects/Governance/Schemas/App-Schema/pool-weight-vote.json new file mode 100644 index 000000000..05a8deeeb --- /dev/null +++ b/Projects/Governance/Schemas/App-Schema/pool-weight-vote.json @@ -0,0 +1,40 @@ +{ + "type": "Pool Weight Vote", + "menuItems": [ + { + "action": "Configure", + "actionFunction": "uiObject.configEditor.activate", + "label": "Configure", + "iconPathOn": "configuration", + "iconPathOff": "configuration" + }, + { + "action": "Delete UI Object", + "askConfirmation": true, + "confirmationLabel": "Confirm to Delete", + "label": "Delete", + "iconPathOn": "delete-entity", + "iconPathOff": "delete-entity", + "actionFunction": "payload.executeAction" + } + ], + "title": [ + "Use Reference Parent", + "Use Reference Parent Type" + ], + "editors": { + "config": true + }, + "initialValues": { + "config": "{\n \"description\": \"\"\n}" + }, + "addLeftIcons": true, + "level": 2, + "attachingRules": { + "compatibleTypes": "->Votes Switch->" + }, + "referencingRules": { + "compatibleTypes": "->Tokens Switch->Pool->" + }, + "propertyNameAtParent": "poolWeightVotes" +} \ No newline at end of file diff --git a/Projects/Governance/Schemas/App-Schema/governance-contributions.json b/Projects/Governance/Schemas/App-Schema/pool.json similarity index 69% rename from Projects/Governance/Schemas/App-Schema/governance-contributions.json rename to Projects/Governance/Schemas/App-Schema/pool.json index 6971afbe7..8eb58308d 100644 --- a/Projects/Governance/Schemas/App-Schema/governance-contributions.json +++ b/Projects/Governance/Schemas/App-Schema/pool.json @@ -1,5 +1,5 @@ { - "type": "Time Contributions", + "type": "Pool", "menuItems": [ { "action": "Configure", @@ -11,14 +11,14 @@ { "action": "Add UI Object", "actionFunction": "payload.executeAction", - "label": "Add Time Contributions", - "relatedUiObject": "Time Contributions" + "label": "Add Tokens Switch", + "relatedUiObject": "Tokens Switch" }, { "action": "Add UI Object", "actionFunction": "payload.executeAction", - "label": "Add Contributed Time", - "relatedUiObject": "Contributed Time" + "label": "Add Pool", + "relatedUiObject": "Pool" }, { "action": "Delete UI Object", @@ -39,22 +39,24 @@ "addLeftIcons": true, "level": 2, "attachingRules": { - "compatibleTypes": "->User Profile->Time Contributions->" + "compatibleTypes": "->Tokens Switch->Pool->" }, - "propertyNameAtParent": "timeContributions", + "referencingRules": { + "compatibleTypes": "->Positions->Assets->Features->" + }, + "propertyNameAtParent": "pools", "childrenNodesProperties": [ { - "name": "timeContributions", + "name": "tokensSwitches", "type": "array", - "childType": "Time Contributions", + "childType": "Tokens Switch", "autoAdd": false }, { - "name": "contributedTimes", + "name": "pools", "type": "array", - "childType": "Contributed Time", + "childType": "Pool", "autoAdd": false } - ], - "icon": "bitcoin" + ] } \ No newline at end of file diff --git a/Projects/Governance/Schemas/App-Schema/pools.json b/Projects/Governance/Schemas/App-Schema/pools.json new file mode 100644 index 000000000..6f0c78625 --- /dev/null +++ b/Projects/Governance/Schemas/App-Schema/pools.json @@ -0,0 +1,56 @@ +{ + "type": "Pools", + "menuItems": [ + { + "action": "Configure", + "actionFunction": "uiObject.configEditor.activate", + "label": "Configure", + "iconPathOn": "configuration", + "iconPathOff": "configuration" + }, + { + "action": "Add UI Object", + "actionFunction": "payload.executeAction", + "label": "Add Tokens Switch", + "relatedUiObject": "Tokens Switch" + }, + { + "action": "Add UI Object", + "actionFunction": "payload.executeAction", + "label": "Add Pool", + "relatedUiObject": "Pool" + }, + { + "action": "Delete UI Object", + "askConfirmation": true, + "confirmationLabel": "Confirm to Delete", + "label": "Delete", + "iconPathOn": "delete-entity", + "iconPathOff": "delete-entity", + "actionFunction": "payload.executeAction" + } + ], + "editors": { + "config": true + }, + "initialValues": { + "config": "{\n \"token\": \"\"\n}" + }, + "isHierarchyHead": true, + "addLeftIcons": true, + "level": 0, + "childrenNodesProperties": [ + { + "name": "tokensSwitches", + "type": "array", + "childType": "Tokens Switch", + "autoAdd": false + }, + { + "name": "pools", + "type": "array", + "childType": "Pool", + "autoAdd": false + } + ] +} \ No newline at end of file diff --git a/Projects/Governance/Schemas/App-Schema/position-claim-vote.json b/Projects/Governance/Schemas/App-Schema/position-claim-vote.json new file mode 100644 index 000000000..b77163f27 --- /dev/null +++ b/Projects/Governance/Schemas/App-Schema/position-claim-vote.json @@ -0,0 +1,41 @@ +{ + "type": "Position Claim Vote", + "menuItems": [ + { + "action": "Configure", + "actionFunction": "uiObject.configEditor.activate", + "label": "Configure", + "iconPathOn": "configuration", + "iconPathOff": "configuration" + }, + { + "action": "Delete UI Object", + "askConfirmation": true, + "confirmationLabel": "Confirm to Delete", + "label": "Delete", + "iconPathOn": "delete-entity", + "iconPathOff": "delete-entity", + "actionFunction": "payload.executeAction" + } + ], + "title": [ + "Reference Parent Find In Parents Node Type->User Profile", + "Use Reference Parent" + ], + "editors": { + "config": true + }, + "initialValues": { + "config": "{\n \"description\": \"\"\n}" + }, + "addLeftIcons": true, + "level": 2, + "attachingRules": { + "compatibleTypes": "->Votes Switch->" + }, + "referencingRules": { + "compatibleTypes": "->Position Contribution Claim->" + }, + "propertyNameAtParent": "positionClaimVotes", + "icon": "dogecoin" +} \ No newline at end of file diff --git a/Projects/Governance/Schemas/App-Schema/team.json b/Projects/Governance/Schemas/App-Schema/position-class.json similarity index 73% rename from Projects/Governance/Schemas/App-Schema/team.json rename to Projects/Governance/Schemas/App-Schema/position-class.json index af27c192c..78c6c07d9 100644 --- a/Projects/Governance/Schemas/App-Schema/team.json +++ b/Projects/Governance/Schemas/App-Schema/position-class.json @@ -1,5 +1,5 @@ { - "type": "Team", + "type": "Position Class", "menuItems": [ { "action": "Configure", @@ -11,14 +11,14 @@ { "action": "Add UI Object", "actionFunction": "payload.executeAction", - "label": "Add Ranking Position", - "relatedUiObject": "Ranking Position" + "label": "Add Position", + "relatedUiObject": "Position" }, { "action": "Add UI Object", "actionFunction": "payload.executeAction", - "label": "Add Team", - "relatedUiObject": "Team" + "label": "Add Position Class", + "relatedUiObject": "Position Class" }, { "action": "Delete UI Object", @@ -39,20 +39,20 @@ "addLeftIcons": true, "level": 2, "attachingRules": { - "compatibleTypes": "->Ranking Position->Team->" + "compatibleTypes": "->Position->Position Class->" }, - "propertyNameAtParent": "teams", + "propertyNameAtParent": "positionClasss", "childrenNodesProperties": [ { - "name": "rankingPositions", + "name": "positions", "type": "array", - "childType": "Ranking Position", + "childType": "Position", "autoAdd": false }, { - "name": "teams", + "name": "positionClasss", "type": "array", - "childType": "Team", + "childType": "Position Class", "autoAdd": false } ], diff --git a/Projects/Governance/Schemas/App-Schema/contributed-time.json b/Projects/Governance/Schemas/App-Schema/position-contribution-claim.json similarity index 82% rename from Projects/Governance/Schemas/App-Schema/contributed-time.json rename to Projects/Governance/Schemas/App-Schema/position-contribution-claim.json index 9895ec408..b6010510f 100644 --- a/Projects/Governance/Schemas/App-Schema/contributed-time.json +++ b/Projects/Governance/Schemas/App-Schema/position-contribution-claim.json @@ -1,5 +1,5 @@ { - "type": "Contributed Time", + "type": "Position Contribution Claim", "menuItems": [ { "action": "Configure", @@ -31,11 +31,11 @@ "addLeftIcons": true, "level": 2, "attachingRules": { - "compatibleTypes": "->Time Contributions->" + "compatibleTypes": "->Position Contributions Folder->" }, "referencingRules": { - "compatibleTypes": "->Ranking Position->" + "compatibleTypes": "->Position->" }, - "propertyNameAtParent": "contributedTimes", + "propertyNameAtParent": "positionContributionClaims", "icon": "dogecoin" } \ No newline at end of file diff --git a/Projects/Governance/Schemas/App-Schema/software-contributions.json b/Projects/Governance/Schemas/App-Schema/position-contributions-folder.json similarity index 65% rename from Projects/Governance/Schemas/App-Schema/software-contributions.json rename to Projects/Governance/Schemas/App-Schema/position-contributions-folder.json index 4d849c93b..8f449997c 100644 --- a/Projects/Governance/Schemas/App-Schema/software-contributions.json +++ b/Projects/Governance/Schemas/App-Schema/position-contributions-folder.json @@ -1,5 +1,5 @@ { - "type": "Software Contributions", + "type": "Position Contributions Folder", "menuItems": [ { "action": "Configure", @@ -11,14 +11,14 @@ { "action": "Add UI Object", "actionFunction": "payload.executeAction", - "label": "Add Software Contributions", - "relatedUiObject": "Software Contributions" + "label": "Add Position Contributions Folder", + "relatedUiObject": "Position Contributions Folder" }, { "action": "Add UI Object", "actionFunction": "payload.executeAction", - "label": "Add Contributed Asset", - "relatedUiObject": "Contributed Asset" + "label": "Add Position Contribution Claim", + "relatedUiObject": "Position Contribution Claim" }, { "action": "Delete UI Object", @@ -39,20 +39,20 @@ "addLeftIcons": true, "level": 2, "attachingRules": { - "compatibleTypes": "->User Profile->Software Contributions->" + "compatibleTypes": "->Contribution Claims->Position Contributions Folder->" }, - "propertyNameAtParent": "softwareContributions", + "propertyNameAtParent": "positionContributionsFolder", "childrenNodesProperties": [ { - "name": "softwareContributions", + "name": "positionContributionsFolder", "type": "array", - "childType": "Software Contributions", + "childType": "Position Contributions Folder", "autoAdd": false }, { - "name": "contributedAssets", + "name": "positionContributionClaims", "type": "array", - "childType": "Contributed Asset", + "childType": "Position Contribution Claim", "autoAdd": false } ], diff --git a/Projects/Governance/Schemas/App-Schema/ranking-vote.json b/Projects/Governance/Schemas/App-Schema/position-weight-vote.json similarity index 83% rename from Projects/Governance/Schemas/App-Schema/ranking-vote.json rename to Projects/Governance/Schemas/App-Schema/position-weight-vote.json index 079065718..c1cb72fc8 100644 --- a/Projects/Governance/Schemas/App-Schema/ranking-vote.json +++ b/Projects/Governance/Schemas/App-Schema/position-weight-vote.json @@ -1,5 +1,5 @@ { - "type": "Ranking Vote", + "type": "Position Weight Vote", "menuItems": [ { "action": "Configure", @@ -31,11 +31,11 @@ "addLeftIcons": true, "level": 2, "attachingRules": { - "compatibleTypes": "->Civic Contributions->" + "compatibleTypes": "->Votes Switch->" }, "referencingRules": { - "compatibleTypes": "->Team->Ranking Position->" + "compatibleTypes": "->Position Class->Position->" }, - "propertyNameAtParent": "rankingVotes", + "propertyNameAtParent": "positionWeightVotes", "icon": "bitfinex" } \ No newline at end of file diff --git a/Projects/Governance/Schemas/App-Schema/position.json b/Projects/Governance/Schemas/App-Schema/position.json new file mode 100644 index 000000000..36a2bcac5 --- /dev/null +++ b/Projects/Governance/Schemas/App-Schema/position.json @@ -0,0 +1,60 @@ +{ + "type": "Position", + "menuItems": [ + { + "action": "Configure", + "actionFunction": "uiObject.configEditor.activate", + "label": "Configure", + "iconPathOn": "configuration", + "iconPathOff": "configuration" + }, + { + "action": "Add UI Object", + "actionFunction": "payload.executeAction", + "label": "Add Position", + "relatedUiObject": "Position" + }, + { + "action": "Add UI Object", + "actionFunction": "payload.executeAction", + "label": "Add Position Class", + "relatedUiObject": "Position Class" + }, + { + "action": "Delete UI Object", + "askConfirmation": true, + "confirmationLabel": "Confirm to Delete", + "label": "Delete", + "iconPathOn": "delete-entity", + "iconPathOff": "delete-entity", + "actionFunction": "payload.executeAction" + } + ], + "editors": { + "config": true + }, + "initialValues": { + "config": "{\n \"description\": \"\" \n}" + }, + "addLeftIcons": true, + "level": 2, + "attachingRules": { + "compatibleTypes": "->Positions->Position->Position Class->" + }, + "propertyNameAtParent": "positions", + "childrenNodesProperties": [ + { + "name": "positions", + "type": "array", + "childType": "Position", + "autoAdd": false + }, + { + "name": "positionClasss", + "type": "array", + "childType": "Position Class", + "autoAdd": false + } + ], + "icon": "bitfinex" +} \ No newline at end of file diff --git a/Projects/Governance/Schemas/App-Schema/governance-structure.json b/Projects/Governance/Schemas/App-Schema/positions.json similarity index 55% rename from Projects/Governance/Schemas/App-Schema/governance-structure.json rename to Projects/Governance/Schemas/App-Schema/positions.json index 79c5de3d3..f8b062da9 100644 --- a/Projects/Governance/Schemas/App-Schema/governance-structure.json +++ b/Projects/Governance/Schemas/App-Schema/positions.json @@ -1,10 +1,16 @@ { - "type": "Ranking", + "type": "Positions", "menuItems": [ { "action": "Add UI Object", - "label": "Add Ranking Position", - "relatedUiObject": "Ranking Position", + "actionFunction": "payload.executeAction", + "label": "Add Position Class", + "relatedUiObject": "Position Class" + }, + { + "action": "Add UI Object", + "label": "Add Position", + "relatedUiObject": "Position", "actionFunction": "payload.executeAction" }, { @@ -17,15 +23,20 @@ "actionFunction": "payload.executeAction" } ], - "isTitleAllwaysVisible": false, "isHierarchyHead": true, "addLeftIcons": true, "level": 0, "childrenNodesProperties": [ { - "name": "rankingPositions", + "name": "positionClasss", "type": "array", - "childType": "Ranking Position", + "childType": "Position Class", + "autoAdd": false + }, + { + "name": "positions", + "type": "array", + "childType": "Position", "autoAdd": false } ], diff --git a/Projects/Governance/Schemas/App-Schema/user-profile.json b/Projects/Governance/Schemas/App-Schema/user-profile.json index 91d3cac6c..e23848ce0 100644 --- a/Projects/Governance/Schemas/App-Schema/user-profile.json +++ b/Projects/Governance/Schemas/App-Schema/user-profile.json @@ -10,33 +10,27 @@ }, { "action": "Add UI Object", - "label": "Add Software Contributions", - "relatedUiObject": "Software Contributions", - "actionFunction": "payload.executeAction" + "disableIfPropertyIsDefined": true, + "propertyToCheckFor": "contributionClaims", + "actionFunction": "payload.executeAction", + "label": "Add Contribution Claims", + "relatedUiObject": "Contribution Claims" }, { "action": "Add UI Object", + "disableIfPropertyIsDefined": true, + "propertyToCheckFor": "votesDistribution", "actionFunction": "payload.executeAction", - "label": "Add Marketing Contributions", - "relatedUiObject": "Marketing Contributions" + "label": "Add Votes Distribution", + "relatedUiObject": "Votes Distribution" }, { "action": "Add UI Object", + "disableIfPropertyIsDefined": true, + "propertyToCheckFor": "referrer", "actionFunction": "payload.executeAction", - "label": "Add Community Contributions", - "relatedUiObject": "Community Contributions" - }, - { - "action": "Add UI Object", - "actionFunction": "payload.executeAction", - "label": "Add Time Contributions", - "relatedUiObject": "Time Contributions" - }, - { - "action": "Add UI Object", - "actionFunction": "payload.executeAction", - "label": "Add Civic Contributions", - "relatedUiObject": "Civic Contributions" + "label": "Add Referrer", + "relatedUiObject": "Referrer" }, { "action": "Delete UI Object", @@ -60,33 +54,21 @@ "level": 0, "childrenNodesProperties": [ { - "name": "softwareContributions", - "type": "array", - "childType": "Software Contributions", + "name": "contributionClaims", + "type": "node", + "childType": "Contribution Claims", "autoAdd": false }, { - "name": "marketingContributions", - "type": "array", - "childType": "Marketing Contributions", + "name": "votesDistribution", + "type": "node", + "childType": "Votes Distribution", "autoAdd": false }, { - "name": "communityContributions", - "type": "array", - "childType": "Community Contributions", - "autoAdd": false - }, - { - "name": "timeContributions", - "type": "array", - "childType": "Time Contributions", - "autoAdd": false - }, - { - "name": "civicContributions", - "type": "array", - "childType": "Civic Contributions", + "name": "referrer", + "type": "node", + "childType": "Referrer", "autoAdd": false } ] diff --git a/Projects/Governance/Schemas/App-Schema/user-vote.json b/Projects/Governance/Schemas/App-Schema/user-vote-transfer.json similarity index 88% rename from Projects/Governance/Schemas/App-Schema/user-vote.json rename to Projects/Governance/Schemas/App-Schema/user-vote-transfer.json index f74d785b8..90bc622b7 100644 --- a/Projects/Governance/Schemas/App-Schema/user-vote.json +++ b/Projects/Governance/Schemas/App-Schema/user-vote-transfer.json @@ -1,5 +1,5 @@ { - "type": "User Vote", + "type": "User Vote Transfer", "menuItems": [ { "action": "Configure", @@ -30,11 +30,11 @@ "addLeftIcons": true, "level": 2, "attachingRules": { - "compatibleTypes": "->Civic Contributions->" + "compatibleTypes": "->Votes Switch->" }, "referencingRules": { "compatibleTypes": "->User Profile->" }, - "propertyNameAtParent": "userVotes", + "propertyNameAtParent": "userVoteTransfers", "icon": "user-profile" } \ No newline at end of file diff --git a/Projects/Governance/Schemas/App-Schema/votes-distribution.json b/Projects/Governance/Schemas/App-Schema/votes-distribution.json new file mode 100644 index 000000000..cc428a388 --- /dev/null +++ b/Projects/Governance/Schemas/App-Schema/votes-distribution.json @@ -0,0 +1,56 @@ +{ + "type": "Votes Distribution", + "menuItems": [ + { + "action": "Configure", + "actionFunction": "uiObject.configEditor.activate", + "label": "Configure", + "iconPathOn": "configuration", + "iconPathOff": "configuration" + }, + { + "action": "Add UI Object", + "actionFunction": "payload.executeAction", + "label": "Add Votes Switch", + "relatedUiObject": "Votes Switch" + }, + { + "action": "Add UI Object", + "disableIfPropertyIsDefined": true, + "propertyToCheckFor": "referrer", + "actionFunction": "payload.executeAction", + "label": "Add Referrer", + "relatedUiObject": "Referrer" + }, + { + "action": "Delete UI Object", + "askConfirmation": true, + "confirmationLabel": "Confirm to Delete", + "label": "Delete", + "iconPathOn": "delete-entity", + "iconPathOff": "delete-entity", + "actionFunction": "payload.executeAction" + } + ], + "editors": { + "config": true + }, + "initialValues": { + "config": "{\n\"codeName\": \"\"\n}" + }, + "attachingRules": { + "compatibleTypes": "->User Profile->" + }, + "addLeftIcons": true, + "level": 1, + "propertyNameAtParent": "votesDistribution", + "childrenNodesProperties": [ + { + "name": "votesSwitch", + "type": "array", + "childType": "Votes Switch", + "autoAdd": false + } + ], + "icon": "bitcoin" +} \ No newline at end of file diff --git a/Projects/Governance/Schemas/App-Schema/votes-switch.json b/Projects/Governance/Schemas/App-Schema/votes-switch.json new file mode 100644 index 000000000..4f4c0fd66 --- /dev/null +++ b/Projects/Governance/Schemas/App-Schema/votes-switch.json @@ -0,0 +1,144 @@ +{ + "type": "Votes Switch", + "menuItems": [ + { + "action": "Configure", + "actionFunction": "uiObject.configEditor.activate", + "label": "Configure", + "iconPathOn": "configuration", + "iconPathOff": "configuration" + }, + { + "action": "Add UI Object", + "actionFunction": "payload.executeAction", + "label": "Add Votes Switch", + "relatedUiObject": "Votes Switch" + }, + { + "action": "Add UI Object", + "actionFunction": "payload.executeAction", + "label": "Add Pool Weight Vote", + "relatedUiObject": "Pool Weight Vote" + }, + { + "action": "Add UI Object", + "actionFunction": "payload.executeAction", + "label": "Add Position Weight Vote", + "relatedUiObject": "Position Weight Vote" + }, + { + "action": "Add UI Object", + "actionFunction": "payload.executeAction", + "label": "Add Asset Weight Vote", + "relatedUiObject": "Asset Weight Vote" + }, + { + "action": "Add UI Object", + "actionFunction": "payload.executeAction", + "label": "Add Feature Weight Vote", + "relatedUiObject": "Feature Weight Vote" + }, + { + "action": "Add UI Object", + "actionFunction": "payload.executeAction", + "label": "Add Position Claim Vote", + "relatedUiObject": "Position Claim Vote" + }, + { + "action": "Add UI Object", + "actionFunction": "payload.executeAction", + "label": "Add Asset Claim Vote", + "relatedUiObject": "Asset Claim Vote" + }, + { + "action": "Add UI Object", + "actionFunction": "payload.executeAction", + "label": "Add Feature Claim Vote", + "relatedUiObject": "Feature Claim Vote" + }, + { + "action": "Add UI Object", + "actionFunction": "payload.executeAction", + "label": "Add User Vote Transfer", + "relatedUiObject": "User Vote Transfer" + }, + { + "action": "Delete UI Object", + "askConfirmation": true, + "confirmationLabel": "Confirm to Delete", + "label": "Delete", + "iconPathOn": "delete-entity", + "iconPathOff": "delete-entity", + "actionFunction": "payload.executeAction" + } + ], + "editors": { + "config": true + }, + "initialValues": { + "config": "{\n \"description\": \"\"\n}" + }, + "addLeftIcons": true, + "level": 2, + "attachingRules": { + "compatibleTypes": "->Votes Distribution->Votes Switch->" + }, + "propertyNameAtParent": "votesSwitch", + "childrenNodesProperties": [ + { + "name": "votesSwitch", + "type": "array", + "childType": "Votes Switch", + "autoAdd": false + }, + { + "name": "poolWeightVotes", + "type": "array", + "childType": "Pool Weight Vote", + "autoAdd": false + }, + { + "name": "assetWeightVotes", + "type": "array", + "childType": "Asset Weight Vote", + "autoAdd": false + }, + { + "name": "featureWeightVotes", + "type": "array", + "childType": "Feature Weight Vote", + "autoAdd": false + }, + { + "name": "positionClaimVotes", + "type": "array", + "childType": "Position Claim Vote", + "autoAdd": false + }, + { + "name": "assetClaimVotes", + "type": "array", + "childType": "Asset Claim Vote", + "autoAdd": false + }, + { + "name": "featureClaimVotes", + "type": "array", + "childType": "Feature Claim Vote", + "autoAdd": false + }, + { + "name": "positionWeightVotes", + "type": "array", + "childType": "Position Weight Vote", + "autoAdd": false + }, + { + "name": "userVoteTransfers", + "type": "array", + "childType": "User Vote Transfer", + "autoAdd": false + } + ], + "icon": "bitcoin" +} \ No newline at end of file diff --git a/Projects/Governance/UI/Spaces/User-Contributions-Space/UserContributions.js b/Projects/Governance/UI/Spaces/Features-Space/Features.js similarity index 88% rename from Projects/Governance/UI/Spaces/User-Contributions-Space/UserContributions.js rename to Projects/Governance/UI/Spaces/Features-Space/Features.js index 456b300c0..3573a4dca 100644 --- a/Projects/Governance/UI/Spaces/User-Contributions-Space/UserContributions.js +++ b/Projects/Governance/UI/Spaces/Features-Space/Features.js @@ -1,5 +1,5 @@ -function newGovernanceUserContributionsSpace() { - const MODULE_NAME = 'User Contributions Space' +function newGovernanceFeaturesSpace() { + const MODULE_NAME = 'Features Space' let thisObject = { container: undefined, diff --git a/Projects/Governance/UI/Spaces/Pools-Space/Pools.js b/Projects/Governance/UI/Spaces/Pools-Space/Pools.js new file mode 100644 index 000000000..d4fc6b3ae --- /dev/null +++ b/Projects/Governance/UI/Spaces/Pools-Space/Pools.js @@ -0,0 +1,185 @@ +function newGovernancePoolsSpace() { + const MODULE_NAME = 'Pool Space' + + let thisObject = { + container: undefined, + physics: physics, + draw: draw, + getContainer: getContainer, + finalize: finalize, + initialize: initialize + } + + thisObject.container = newContainer() + thisObject.container.initialize(MODULE_NAME) + + return thisObject + + function initialize() { + + } + + function finalize() { + thisObject.container.finalize() + thisObject.container = undefined + } + + function getContainer(point) { + + if (thisObject.container.frame.isThisPointHere(point, true) === true) { + thisObject.container.space = MODULE_NAME + return thisObject.container + } else { + return undefined + } + } + + function physics() { + if (UI.projects.superalgos.spaces.designSpace.workspace === undefined) { return } + + let pools = UI.projects.superalgos.spaces.designSpace.workspace.getHierarchyHeadsByNodeType('Pools') + + /* + We will first reset all the token flows, and then distribute it. + */ + for (let i = 0; i < pools.length; i++) { + let poolsNode = pools[i] + poolsReset(poolsNode) + } + for (let i = 0; i < pools.length; i++) { + let poolsNode = pools[i] + poolsDistribute(poolsNode) + } + } + + function poolsReset(pools) { + resetTokenFlow(pools) + } + + function poolsDistribute(pools) { + let tokenFlow = UI.projects.superalgos.utilities.nodeConfig.loadPropertyFromNodeConfig(pools.payload, 'tokens') + distributeTokenFlow(pools, tokenFlow) + } + + function resetTokenFlow(node) { + if (node === undefined) { return } + if (node.payload === undefined) { return } + node.payload.tokenFlow = 0 + /* + If there is a reference parent defined, this means that the token flow is + transfered to it and not distributed among children. + */ + if (node.payload.referenceParent !== undefined) { + resetTokenFlow(node.payload.referenceParent) + return + } + /* + When we reach certain node types, we will halt the distribution, because thse are targets for + token flow. + */ + if ( + node.type === 'Position' || + node.type === 'Asset' || + node.type === 'Feature' + ) { return } + /* + If there is no reference parent we will redistribute token flow among children. + */ + let schemaDocument = getSchemaDocument(node) + if (schemaDocument === undefined) { return } + + if (schemaDocument.childrenNodesProperties !== undefined) { + for (let i = 0; i < schemaDocument.childrenNodesProperties.length; i++) { + let property = schemaDocument.childrenNodesProperties[i] + + switch (property.type) { + case 'node': { + if (node.type === 'Pools' && property.name === "votesDistribution") { + let childNode = node[property.name] + resetTokenFlow(childNode) + } + } + break + case 'array': { + let propertyArray = node[property.name] + if (propertyArray !== undefined) { + for (let m = 0; m < propertyArray.length; m++) { + let childNode = propertyArray[m] + resetTokenFlow(childNode) + } + } + break + } + } + } + } + } + + function distributeTokenFlow(node, tokenFlow) { + if (node === undefined) { return } + if (node.payload === undefined) { return } + node.payload.tokenFlow = node.payload.tokenFlow + tokenFlow + drawTokenFlow(node, node.payload.tokenFlow) + /* + If there is a reference parent defined, this means that the token flow is + transfered to it and not distributed among children. + */ + if (node.payload.referenceParent !== undefined) { + distributeTokenFlow(node.payload.referenceParent, tokenFlow) + return + } + /* + When we reach certain node types, we will halt the distribution, because thse are targets for + token flow. + */ + if ( + node.type === 'Asset' || + node.type === 'Feature' + ) { return } + /* + If there is no reference parent we will redistribute token flow among children. + */ + let schemaDocument = getSchemaDocument(node) + if (schemaDocument === undefined) { return } + + if (schemaDocument.childrenNodesProperties !== undefined) { + for (let i = 0; i < schemaDocument.childrenNodesProperties.length; i++) { + let property = schemaDocument.childrenNodesProperties[i] + + switch (property.type) { + case 'node': { + if (node.type === 'Pools' && property.name === "votesDistribution") { + let childNode = node[property.name] + distributeTokenFlow(childNode, tokenFlow) + } + } + break + case 'array': { + let propertyArray = node[property.name] + if (propertyArray !== undefined) { + for (let m = 0; m < propertyArray.length; m++) { + let childNode = propertyArray[m] + distributeTokenFlow(childNode, tokenFlow / propertyArray.length) + } + } + break + } + } + } + } + } + + function drawTokenFlow(node, tokenFlow) { + tokenFlow = new Intl.NumberFormat().format(tokenFlow) + ' ' + 'SA Tokens' + if (node.payload !== undefined) { + if (node.type === 'Pools') { + return + } + node.payload.uiObject.setStatus(tokenFlow) + } + } + + function draw() { + + } +} diff --git a/Projects/Governance/UI/Spaces/Ranking-Space/Ranking.js b/Projects/Governance/UI/Spaces/Positions-Space/Positions.js similarity index 90% rename from Projects/Governance/UI/Spaces/Ranking-Space/Ranking.js rename to Projects/Governance/UI/Spaces/Positions-Space/Positions.js index f797e8ac4..f6407b32c 100644 --- a/Projects/Governance/UI/Spaces/Ranking-Space/Ranking.js +++ b/Projects/Governance/UI/Spaces/Positions-Space/Positions.js @@ -1,5 +1,5 @@ -function newGovernanceRankingSpace() { - const MODULE_NAME = 'Ranking Space' +function newGovernancePositionsSpace() { + const MODULE_NAME = 'Positions Space' let thisObject = { container: undefined, @@ -27,7 +27,7 @@ function newGovernanceRankingSpace() { } function physics() { - + } function getContainer(point) { diff --git a/Projects/Governance/UI/Spaces/User-Profile-Space/UserProfile.js b/Projects/Governance/UI/Spaces/User-Profile-Space/UserProfile.js new file mode 100644 index 000000000..8fe109aa6 --- /dev/null +++ b/Projects/Governance/UI/Spaces/User-Profile-Space/UserProfile.js @@ -0,0 +1,207 @@ +function newGovernanceUserProfileSpace() { + const MODULE_NAME = 'User Profile Space' + + let thisObject = { + container: undefined, + physics: physics, + draw: draw, + getContainer: getContainer, + finalize: finalize, + initialize: initialize + } + + thisObject.container = newContainer() + thisObject.container.initialize(MODULE_NAME) + + return thisObject + + function initialize() { + + } + + function finalize() { + thisObject.container.finalize() + thisObject.container = undefined + } + + function getContainer(point) { + + if (thisObject.container.frame.isThisPointHere(point, true) === true) { + thisObject.container.space = MODULE_NAME + return thisObject.container + } else { + return undefined + } + } + + function physics() { + if (UI.projects.superalgos.spaces.designSpace.workspace === undefined) { return } + + let userProfiles = UI.projects.superalgos.spaces.designSpace.workspace.getHierarchyHeadsByNodeType('User Profile') + + /* + We will first reset all the voting power, and then distribute it. + */ + for (let i = 0; i < userProfiles.length; i++) { + let userProfile = userProfiles[i] + userProfileReset(userProfile) + } + for (let i = 0; i < userProfiles.length; i++) { + let userProfile = userProfiles[i] + userProfileDistribute(userProfile) + } + } + + function userProfileReset(userProfile) { + resetVotingPower(userProfile) + } + + function userProfileDistribute(userProfile) { + let votingPower = UI.projects.superalgos.utilities.nodeConfig.loadPropertyFromNodeConfig(userProfile.payload, 'tokens') + distributeVotingPower(userProfile, votingPower) + } + + function resetVotingPower(node) { + if (node === undefined) { return } + if (node.payload === undefined) { return } + node.payload.votingPower = 0 + /* + If there is a reference parent defined, this means that the voting power is + transfered to it and not distributed among children. + */ + if (node.payload.referenceParent !== undefined) { + resetVotingPower(node.payload.referenceParent) + return + } + /* + When we reach certain node types, we will halt the distribution, because thse are targets for + voting power. + */ + if ( + node.type === 'Position' || + node.type === 'Asset' || + node.type === 'Feature' + ) { return } + /* + If there is no reference parent we will redistribute voting power among children. + */ + let schemaDocument = getSchemaDocument(node) + if (schemaDocument === undefined) { return } + + if (schemaDocument.childrenNodesProperties !== undefined) { + for (let i = 0; i < schemaDocument.childrenNodesProperties.length; i++) { + let property = schemaDocument.childrenNodesProperties[i] + + if (node.type === 'User Profile' && property.name !== "votesDistribution") { continue } + + switch (property.type) { + case 'node': { + if (node.type === 'User Profile' && property.name === "votesDistribution") { + let childNode = node[property.name] + resetVotingPower(childNode) + } + } + break + case 'array': { + let propertyArray = node[property.name] + if (propertyArray !== undefined) { + for (let m = 0; m < propertyArray.length; m++) { + let childNode = propertyArray[m] + resetVotingPower(childNode) + } + } + break + } + } + } + } + } + + function distributeVotingPower(node, votingPower) { + if (node === undefined) { return } + if (node.payload === undefined) { return } + node.payload.votingPower = node.payload.votingPower + votingPower + drawVotingPower(node, node.payload.votingPower) + /* + If there is a reference parent defined, this means that the voting power is + transfered to it and not distributed among children. + */ + if (node.payload.referenceParent !== undefined) { + distributeVotingPower(node.payload.referenceParent, votingPower) + return + } + /* + When we reach certain node types, we will halt the distribution, because thse are targets for + voting power. + */ + if ( + node.type === 'Position' || + node.type === 'Asset' || + node.type === 'Feature' + ) { return } + /* + If there is no reference parent we will redistribute voting power among children. + */ + let schemaDocument = getSchemaDocument(node) + if (schemaDocument === undefined) { return } + + if (schemaDocument.childrenNodesProperties !== undefined) { + for (let i = 0; i < schemaDocument.childrenNodesProperties.length; i++) { + let property = schemaDocument.childrenNodesProperties[i] + + if (node.type === 'User Profile' && property.name !== "votesDistribution") { continue } + + switch (property.type) { + case 'node': { + if (node.type === 'User Profile' && property.name === "votesDistribution") { + let childNode = node[property.name] + distributeVotingPower(childNode, votingPower) + } + } + break + case 'array': { + let propertyArray = node[property.name] + if (propertyArray !== undefined) { + for (let m = 0; m < propertyArray.length; m++) { + let childNode = propertyArray[m] + distributeVotingPower(childNode, votingPower / propertyArray.length) + } + } + break + } + } + } + } + } + + function drawVotingPower(node, votingPower) { + votingPower = new Intl.NumberFormat().format(votingPower) + ' ' + 'Votes' + if (node.payload !== undefined) { + if (node.type === 'User Profile') { + return + } + if ( + node.type === 'Position' || + node.type === 'Position Class' || + node.type === 'Pool' || + node.type === 'Tokens Switch' || + node.type === 'Asset' || + node.type === 'Asset Class' || + node.type === 'Feature' || + node.type === 'Feature Class' + ) { + node.payload.uiObject.valueAngleOffset = 0 + node.payload.uiObject.valueAtAngle = false + } else{ + node.payload.uiObject.valueAngleOffset = 180 + node.payload.uiObject.valueAtAngle = true + } + + node.payload.uiObject.setValue(votingPower) + } + } + + function draw() { + + } +} diff --git a/Projects/ProjectsSchema.json b/Projects/ProjectsSchema.json index d10fbe1d7..36299a81c 100644 --- a/Projects/ProjectsSchema.json +++ b/Projects/ProjectsSchema.json @@ -1010,10 +1010,10 @@ ], "spaces": [ { - "name": "Assets Space", - "folderName": "Assets-Space", - "propertyName": "assetsSpace", - "functionName": "newGobernanceAssetsSpace", + "name": "User Profile Space", + "folderName": "User-Profile-Space", + "propertyName": "userProfileSpace", + "functionName": "newGovernanceUserProfileSpace", "initializationIndex": 0, "animationPhysicsIndex": 0, "animationDrawIndex": 0, @@ -1023,10 +1023,10 @@ "onMouseDownIndex": 0 }, { - "name": "Ranking Space", - "folderName": "Ranking-Space", - "propertyName": "rankingSpace", - "functionName": "newGovernanceRankingSpace", + "name": "Assets Space", + "folderName": "Assets-Space", + "propertyName": "assetsSpace", + "functionName": "newGobernanceAssetsSpace", "initializationIndex": 1, "animationPhysicsIndex": 1, "animationDrawIndex": 1, @@ -1036,10 +1036,10 @@ "onMouseDownIndex": 1 }, { - "name": "User Contributions Space", - "folderName": "User-Contributions-Space", - "propertyName": "userContributionsSpace", - "functionName": "newGovernanceUserContributionsSpace", + "name": "Features Space", + "folderName": "Features-Space", + "propertyName": "featuresSpace", + "functionName": "newGovernanceFeaturesSpace", "initializationIndex": 2, "animationPhysicsIndex": 2, "animationDrawIndex": 2, @@ -1047,6 +1047,32 @@ "onMouseOverIndex": 2, "onMouseClickIndex": 2, "onMouseDownIndex": 2 + }, + { + "name": "Positions Space", + "folderName": "Positions-Space", + "propertyName": "positionsSpace", + "functionName": "newGovernancePositionsSpace", + "initializationIndex": 3, + "animationPhysicsIndex": 3, + "animationDrawIndex": 3, + "onMouseWheelIndex": 3, + "onMouseOverIndex": 3, + "onMouseClickIndex": 3, + "onMouseDownIndex": 3 + }, + { + "name": "Pools Space", + "folderName": "Pools-Space", + "propertyName": "poolsSpace", + "functionName": "newGovernancePoolsSpace", + "initializationIndex": 4, + "animationPhysicsIndex": 4, + "animationDrawIndex": 4, + "onMouseWheelIndex": 4, + "onMouseOverIndex": 4, + "onMouseClickIndex": 4, + "onMouseDownIndex": 4 } ] }, diff --git a/Projects/Superalgos/UI/Spaces/Floating-Space/UiObject.js b/Projects/Superalgos/UI/Spaces/Floating-Space/UiObject.js index c17d83b09..b239412ae 100644 --- a/Projects/Superalgos/UI/Spaces/Floating-Space/UiObject.js +++ b/Projects/Superalgos/UI/Spaces/Floating-Space/UiObject.js @@ -29,6 +29,7 @@ function newUiObject() { hasWarning: undefined, hasInfo: undefined, valueAtAngle: true, + valueAngleOffset: 0, run: run, stop: stop, heartBeat: heartBeat, @@ -1827,8 +1828,8 @@ function newUiObject() { x: position.x - getTextWidth(label) / 2, y: position.y } - labelPoint.x = labelPoint.x + radius * 7 / 3 * Math.cos(toRadians(thisObject.payload.angle)) - labelPoint.y = labelPoint.y + radius * 7 / 3 * Math.sin(toRadians(thisObject.payload.angle)) + labelPoint.x = labelPoint.x + radius * 7 / 3 * Math.cos(toRadians(thisObject.payload.angle + thisObject.valueAngleOffset)) + labelPoint.y = labelPoint.y + radius * 7 / 3 * Math.sin(toRadians(thisObject.payload.angle + thisObject.valueAngleOffset)) } else { if (thisObject.isOnFocus === true) { labelPoint = { diff --git a/Projects/Superalgos/UI/Spaces/Floating-Space/UiObjectTitle.js b/Projects/Superalgos/UI/Spaces/Floating-Space/UiObjectTitle.js index 5c3b91cda..89c2a3161 100644 --- a/Projects/Superalgos/UI/Spaces/Floating-Space/UiObjectTitle.js +++ b/Projects/Superalgos/UI/Spaces/Floating-Space/UiObjectTitle.js @@ -122,7 +122,7 @@ function newUiObjectTitle() { } case 'Use Reference Parent Type': { let nodeToUse = thisObject.payload.node.payload.referenceParent - if (nodeToUse !== undefined && nodeToUse.payload !== undefined && nodeToUse.payload.node.name !== "New " + nodeToUse.payload.node.type && nodeToUse.payload.node.name !== "My " + nodeToUse.payload.node.type) { + if (nodeToUse !== undefined && nodeToUse.payload !== undefined) { thisObject.payload.title = thisObject.payload.title + separator + nodeToUse.type thisObject.payload.node.name = thisObject.payload.node.name + separator + nodeToUse.type } @@ -189,14 +189,14 @@ function newUiObjectTitle() { thisObject.payload.title = thisObject.payload.title + separator + childNode.name thisObject.payload.node.name = thisObject.payload.node.name + separator + childNode.name } - if (titleReference.indexOf('Find Node Type->') === 0) { + if (titleReference.indexOf('Find In Parents Node Type->') === 0) { let nodeType = titleReference.substring(titleReference.indexOf('->') + 2, titleReference.length) let nodeToUse = UI.projects.superalgos.utilities.meshes.findNodeInNodeMesh( thisObject.payload.node, nodeType, undefined, true, - true, + false, true, false ) @@ -204,14 +204,14 @@ function newUiObjectTitle() { thisObject.payload.title = thisObject.payload.title + separator + nodeToUse.name thisObject.payload.node.name = thisObject.payload.node.name + separator + nodeToUse.name } - if (titleReference.indexOf('Reference Parent Find Node Type->') === 0) { + if (titleReference.indexOf('Reference Parent Find In Parents Node Type->') === 0) { let nodeType = titleReference.substring(titleReference.indexOf('->') + 2, titleReference.length) let nodeToUse = UI.projects.superalgos.utilities.meshes.findNodeInNodeMesh( thisObject.payload.referenceParent, nodeType, undefined, true, - true, + false, true, false )