TeamManager
Inherits:ITEAMMANAGER, Initializable, PausableUpgradeable, AccessControlUpgradeable, ReentrancyGuardUpgradeable, UUPSUpgradeable
Creates and deploys team vesting contracts
Implements a secure and upgradeable team manager with upgrade timelock
Notes:
security-contact: security@nebula-labs.xyz
copyright: Copyright (c) 2025 Nebula Holding Inc. All rights reserved.
oz-upgrades:
State Variables
TEAM_ALLOCATION_PERCENT
Team allocation percentage of total supply (18%)
uint256 private constant TEAM_ALLOCATION_PERCENT = 18;MIN_CLIFF
Minimum cliff period (3 months)
uint64 private constant MIN_CLIFF = 90 days;MAX_CLIFF
Maximum cliff period (1 year)
MIN_DURATION
Minimum vesting duration (1 year)
MAX_DURATION
Maximum vesting duration (4 years)
UPGRADE_TIMELOCK_DURATION
Upgrade timelock duration (4 days)
PAUSER_ROLE
AccessControl Pauser Role
MANAGER_ROLE
AccessControl Manager Role
UPGRADER_ROLE
AccessControl Upgrader Role
ecosystemToken
governance token instance
supply
amount of ecosystem tokens in the contract
totalAllocation
amount of tokens allocated so far
timelock
timelock address
version
number of UUPS upgrades
pendingUpgrade
Pending upgrade information
allocations
token allocations to team members
vestingContracts
vesting contract addresses for team members
__gap
gap for future storage variables (50 - 8 existing variables = 42)
Functions
nonZeroAddress
Modifier to check for non-zero address
Parameters
addr
address
The address to check
nonZeroAmount
Modifier to check for non-zero amount
Parameters
amount
uint256
The amount to check
constructor
Note: oz-upgrades-unsafe-allow: constructor
receive
Prevents receiving Ether
initialize
Initializes the team manager contract
Sets up the initial state of the contract with core functionality
Parameters
token
address
The address of the ecosystem token contract
timelock_
address
The address of the timelock controller
multisig
address
The address receiving UPGRADER_ROLE
pause
Pauses all contract operations
Prevents execution of state-modifying functions
unpause
Resumes all contract operations
Re-enables execution of state-modifying functions
addTeamMember
Create and fund a vesting contract for a new team member
Parameters
beneficiary
address
The address of the team member
amount
uint256
The amount of tokens to vest
cliff
uint256
The cliff period in seconds
duration
uint256
The vesting duration in seconds after cliff
scheduleUpgrade
Schedules an upgrade to a new implementation
Parameters
newImplementation
address
Address of the new implementation
cancelUpgrade
Cancels a previously scheduled upgrade
Only callable by addresses with UPGRADER_ROLE
upgradeTimelockRemaining
Returns the remaining time before a scheduled upgrade can be executed
Returns
<none>
uint256
timeRemaining The time remaining in seconds, or 0 if no upgrade is scheduled or timelock has passed
_authorizeUpgrade
Authorizes and processes contract upgrades with timelock enforcement
Internal override for UUPS upgrade authorization
Parameters
newImplementation
address
Address of the new implementation contract
Last updated