Fraction ProtocolsubInternalFacetsvestingPhaseFacetsdoVestingActionFacetsuniformlyProvidedVesting

UniformlyProvidedVestingFacetStorage

UniformlyProvidedVestingFacetStorage

Works properly only for fungible and semi-fungible wrapped assets (in collaboration with only WrapFungibleAssetFacet from preFractionFacets) WORKS ONLY WITH SEMI-FUNGIBLE FRACTIONS AND GENESIS IDS.

WrongSetAndCheckData

error WrongSetAndCheckData()

Thrown when set and check data is wrong.

InvalidProportions

error InvalidProportions(uint256 tgeProportion, uint256 cliffProportion)

Thrown when the sum of tgeProportion and cliffProportion is greater than 100%.

InvalidPortionInput

error InvalidPortionInput(uint256 totalVestingPeriod, uint256 portionPeriod)

Thrown when attempting pass totalVestingPeriod which is not perfect multiple of portionPeriod.

NonCreator

error NonCreator(uint256 campaignId, address invalidAccount)

Thrown when a non-creator attempts to update a campaign's cliffTimestamp or propose a new tgeLockTimestamp/cliffTimestamp.

InvalidProposal

error InvalidProposal(uint256 campaignId, uint256 timestamp)

Thrown when a proposal for a new timestamp is invalid.

InvalidCliffUpdate

error InvalidCliffUpdate(uint256 campaignId, uint256 currentCliffTimestamp, uint256 requestedCliffTimestamp)

Thrown when attempting to update a campaign's cliffTimestamp to a past time or if vesting has already begun.

NoVestingRewardsAvailableYet

error NoVestingRewardsAvailableYet(uint256 campaignId)

Thrown when campaign's cliff timestamp is not yet reached.

InvalidCombinationOfFacetsForCampaign

error InvalidCombinationOfFacetsForCampaign(uint256 campaignId)

Thrown when a campaign supports minting, whereas this facet cannot be combined with such a case.

InvalidDivisionRemainderBetweenTokenValueAndFractionsCreated

error InvalidDivisionRemainderBetweenTokenValueAndFractionsCreated(uint256 tokenValue, uint256 fractionsCreated)

Thrown when the division tokenValue / fractionsCreated is not a perfect division.

STORAGE_SLOT

bytes32 STORAGE_SLOT

================================================== STORAGE =================================================

Unique identifier for the storage slot where the Layout struct is stored. Derived from the ERC7201 formula. STORAGE_SLOT: 0x4ba1f0d98868e90acdc68ca1b94148b8e2a035741dec434dc404fcf18517e100

ProposalStatus

enum ProposalStatus {
  REJECTED,
  PENDING,
  APPROVED
}

TimestampProposal

struct TimestampProposal {
  uint256 newTimestamp;
  enum UniformlyProvidedVestingFacetStorage.ProposalStatus status;
}

Layout

struct Layout {
  mapping(uint256 => struct UniformlyProvidedVestingFacetStorage.CampaignVestingDetails) campaignVestingDetails;
}

CampaignVestingDetails

struct CampaignVestingDetails {
  uint256 tgeLockTimestamp;
  uint256 tgeProportion;
  uint256 cliffTimestamp;
  uint256 cliffProportion;
  uint256 totalVestingPeriod;
  uint256 portionPeriod;
  uint256 amountOfPortions;
  uint256 vestingEndingTimestamp;
  address[] tokens;
  uint256[] ids;
  uint256[] tokenValuesPerFractionPerPortion;
  struct UniformlyProvidedVestingFacetStorage.TimestampProposal tgeLockTimestampProposal;
  struct UniformlyProvidedVestingFacetStorage.TimestampProposal cliffTimestampProposal;
}

layout

function layout() internal pure returns (struct UniformlyProvidedVestingFacetStorage.Layout l)

Retrieves a reference to the Layout struct stored at a specified storage slot

setAndCheckDoVestingActions

function setAndCheckDoVestingActions(struct UniformlyProvidedVestingFacetStorage.Layout l, bytes postFractionDoVestingActionsData) internal returns (uint256, uint256, uint256, uint256)

_setAndCheckDoVestingActions

function _setAndCheckDoVestingActions(struct UniformlyProvidedVestingFacetStorage.Layout l, uint256 campaignId, uint256 cliffProportion, uint256 tgeProportion, uint256 amountOfPortions) internal

proposeTgeLockTimestamp

function proposeTgeLockTimestamp(struct UniformlyProvidedVestingFacetStorage.Layout l, uint256 campaignId, uint256 newTgeLockTimestamp, address account) internal

approveRejectTgeLockTimestamp

function approveRejectTgeLockTimestamp(struct UniformlyProvidedVestingFacetStorage.Layout l, uint256 campaignId, bool approve) internal returns (uint256 proposedTimestamp)

proposeCliffTimestamp

function proposeCliffTimestamp(struct UniformlyProvidedVestingFacetStorage.Layout l, uint256 campaignId, uint256 newCliffTimestamp, address account) internal

approveRejectCliffTimestamp

function approveRejectCliffTimestamp(struct UniformlyProvidedVestingFacetStorage.Layout l, uint256 campaignId, bool approve) internal returns (uint256 proposedTimestamp)

doVestingActions

function doVestingActions(struct UniformlyProvidedVestingFacetStorage.Layout l, uint256 campaignId, uint256 idToBurn, address account, uint256 amountOfFractions) internal