@agoric/zoe 0.26.3-dev-ecf2d8e.0 → 0.26.3-other-dev-70beeb7.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +1179 -0
- package/README.md +7 -7
- package/bundles/bundle-contractFacet-js-meta.json +319 -543
- package/bundles/bundle-contractFacet.d.ts +3 -3
- package/bundles/bundle-contractFacet.js +1 -1
- package/exported.js +1 -1
- package/package.json +23 -30
- package/src/cleanProposal.js +2 -2
- package/src/contractFacet/internal-types.d.ts +2 -2
- package/src/contractFacet/internal-types.d.ts.map +1 -1
- package/src/contractFacet/internal-types.js +1 -1
- package/src/contractFacet/types.d.ts +191 -0
- package/src/contractFacet/types.d.ts.map +1 -0
- package/src/contractFacet/types.js +256 -0
- package/src/contractFacet/vatRoot.d.ts +1 -1
- package/src/contractFacet/vatRoot.d.ts.map +1 -1
- package/src/contractFacet/zcfMint.d.ts +1 -1
- package/src/contractFacet/zcfMint.d.ts.map +1 -1
- package/src/contractFacet/zcfMint.js +1 -2
- package/src/contractFacet/zcfSeat.d.ts.map +1 -1
- package/src/contractFacet/zcfSeat.js +3 -105
- package/src/contractFacet/zcfZygote.d.ts +1 -1
- package/src/contractFacet/zcfZygote.d.ts.map +1 -1
- package/src/contractFacet/zcfZygote.js +33 -78
- package/src/contractSupport/atomicTransfer.d.ts +6 -0
- package/src/contractSupport/atomicTransfer.d.ts.map +1 -1
- package/src/contractSupport/atomicTransfer.js +90 -5
- package/src/contractSupport/bondingCurves.js +2 -2
- package/src/contractSupport/durability.d.ts +2 -2
- package/src/contractSupport/durability.d.ts.map +1 -1
- package/src/contractSupport/durability.js +3 -3
- package/src/contractSupport/priceAuthority.d.ts +1 -16
- package/src/contractSupport/priceAuthority.d.ts.map +1 -1
- package/src/contractSupport/priceAuthority.js +1 -3
- package/src/contractSupport/priceAuthorityInitial.d.ts.map +1 -1
- package/src/contractSupport/priceAuthorityInitial.js +0 -1
- package/src/contractSupport/priceAuthorityQuoteMint.d.ts +1 -1
- package/src/contractSupport/priceAuthorityQuoteMint.d.ts.map +1 -1
- package/src/contractSupport/priceAuthorityTransform.d.ts.map +1 -1
- package/src/contractSupport/priceAuthorityTransform.js +3 -2
- package/src/contractSupport/recorder.d.ts +4 -4
- package/src/contractSupport/recorder.d.ts.map +1 -1
- package/src/contractSupport/safeMath.d.ts +7 -7
- package/src/contractSupport/safeMath.d.ts.map +1 -1
- package/src/contractSupport/topics.d.ts +1 -1
- package/src/contractSupport/topics.d.ts.map +1 -1
- package/src/contractSupport/zoeHelpers.d.ts +1 -1
- package/src/contractSupport/zoeHelpers.d.ts.map +1 -1
- package/src/contractSupport/zoeHelpers.js +11 -5
- package/src/contracts/atomicSwap.d.ts +1 -1
- package/src/contracts/auction/firstPriceLogic.d.ts.map +1 -1
- package/src/contracts/auction/firstPriceLogic.js +7 -5
- package/src/contracts/auction/index.d.ts +23 -1
- package/src/contracts/auction/index.d.ts.map +1 -1
- package/src/contracts/auction/index.js +0 -1
- package/src/contracts/auction/secondPriceLogic.d.ts.map +1 -1
- package/src/contracts/auction/secondPriceLogic.js +3 -1
- package/src/contracts/automaticRefund.d.ts +3 -3
- package/src/contracts/autoswap.d.ts.map +1 -1
- package/src/contracts/autoswap.js +7 -4
- package/src/contracts/barterExchange.d.ts +2 -2
- package/src/contracts/barterExchange.d.ts.map +1 -1
- package/src/contracts/barterExchange.js +3 -2
- package/src/contracts/callSpread/calculateShares.d.ts +7 -0
- package/src/contracts/callSpread/calculateShares.d.ts.map +1 -1
- package/src/contracts/callSpread/fundedCallSpread.d.ts +1 -1
- package/src/contracts/callSpread/fundedCallSpread.d.ts.map +1 -1
- package/src/contracts/callSpread/fundedCallSpread.js +3 -1
- package/src/contracts/callSpread/payoffHandler.d.ts.map +1 -1
- package/src/contracts/callSpread/payoffHandler.js +0 -1
- package/src/contracts/callSpread/percent.d.ts +2 -0
- package/src/contracts/callSpread/percent.d.ts.map +1 -1
- package/src/contracts/callSpread/pricedCallSpread.d.ts +4 -4
- package/src/contracts/callSpread/pricedCallSpread.d.ts.map +1 -1
- package/src/contracts/callSpread/pricedCallSpread.js +3 -2
- package/src/contracts/coveredCall-durable.d.ts +3 -3
- package/src/contracts/coveredCall.d.ts +1 -1
- package/src/contracts/loan/borrow.d.ts.map +1 -1
- package/src/contracts/loan/borrow.js +3 -1
- package/src/contracts/loan/close.d.ts.map +1 -1
- package/src/contracts/loan/close.js +6 -2
- package/src/contracts/loan/index.d.ts +1 -1
- package/src/contracts/loan/liquidate.d.ts +12 -1
- package/src/contracts/loan/liquidate.d.ts.map +1 -1
- package/src/contracts/loan/liquidate.js +1 -3
- package/src/contracts/loan/scheduleLiquidation.d.ts.map +1 -1
- package/src/contracts/loan/scheduleLiquidation.js +0 -1
- package/src/contracts/loan/types.d.ts +1 -0
- package/src/contracts/loan/types.d.ts.map +1 -1
- package/src/contracts/loan/types.js +7 -0
- package/src/contracts/mintPayments.d.ts +6 -14
- package/src/contracts/mintPayments.d.ts.map +1 -1
- package/src/contracts/mintPayments.js +1 -1
- package/src/contracts/oracle.d.ts +2 -2
- package/src/contracts/oracle.d.ts.map +1 -1
- package/src/contracts/oracle.js +0 -3
- package/src/contracts/priceAggregator.d.ts +12 -2
- package/src/contracts/priceAggregator.d.ts.map +1 -1
- package/src/contracts/priceAggregator.js +2 -3
- package/src/contracts/scaledPriceAuthority.d.ts +1 -1
- package/src/contracts/scaledPriceAuthority.d.ts.map +1 -1
- package/src/contracts/scaledPriceAuthority.js +0 -2
- package/src/contracts/sellItems.d.ts +1 -1
- package/src/contracts/sellItems.d.ts.map +1 -1
- package/src/contracts/sellItems.js +3 -2
- package/src/contracts/simpleExchange.d.ts +2 -2
- package/src/instanceRecordStorage.d.ts +1 -1
- package/src/instanceRecordStorage.d.ts.map +1 -1
- package/src/internal-types.d.ts +3 -3
- package/src/internal-types.d.ts.map +1 -1
- package/src/internal-types.js +1 -1
- package/src/issuerStorage.d.ts +1 -1
- package/src/makeHandle.d.ts +1 -1
- package/src/makeHandle.d.ts.map +1 -1
- package/src/typeGuards.d.ts +20 -118
- package/src/typeGuards.d.ts.map +1 -1
- package/src/typeGuards.js +1 -7
- package/src/zoeService/escrowStorage.d.ts +1 -1
- package/src/zoeService/feeMint.d.ts +5 -5
- package/src/zoeService/feeMint.d.ts.map +1 -1
- package/src/zoeService/installationStorage.d.ts +1 -1
- package/src/zoeService/instanceAdminStorage.d.ts +2 -2
- package/src/zoeService/instanceAdminStorage.d.ts.map +1 -1
- package/src/zoeService/instanceAdminStorage.js +0 -1
- package/src/zoeService/internal-types.d.ts +2 -2
- package/src/zoeService/internal-types.d.ts.map +1 -1
- package/src/zoeService/internal-types.js +1 -1
- package/src/zoeService/makeInvitation.d.ts +1 -1
- package/src/zoeService/makeInvitation.d.ts.map +1 -1
- package/src/zoeService/offer/offer.d.ts.map +1 -1
- package/src/zoeService/offer/offer.js +3 -2
- package/src/zoeService/startInstance.d.ts +1 -1
- package/src/zoeService/startInstance.d.ts.map +1 -1
- package/src/zoeService/startInstance.js +23 -20
- package/src/zoeService/types.d.ts +1 -1
- package/src/zoeService/types.d.ts.map +1 -1
- package/src/zoeService/utils.d.ts +2 -2
- package/src/zoeService/zoe.d.ts +1 -11
- package/src/zoeService/zoe.d.ts.map +1 -1
- package/src/zoeService/zoe.js +1 -24
- package/src/zoeService/zoeSeat.d.ts +1 -1
- package/src/zoeService/zoeSeat.d.ts.map +1 -1
- package/src/zoeService/zoeSeat.js +0 -1
- package/src/zoeService/zoeStorageManager.d.ts +1 -1
- package/src/zoeService/zoeStorageManager.d.ts.map +1 -1
- package/src/zoeService/zoeStorageManager.js +2 -7
- package/tools/fakePriceAuthority.d.ts.map +1 -1
- package/tools/fakePriceAuthority.js +2 -0
- package/tools/manualPriceAuthority.d.ts.map +1 -1
- package/tools/manualPriceAuthority.js +0 -1
- package/tools/manualTimer.js +1 -1
- package/tools/prepare-test-env.js +1 -1
- package/tools/priceAuthorityRegistry.d.ts +1 -1
- package/tools/priceAuthorityRegistry.d.ts.map +1 -1
- package/tools/scriptedOracle.d.ts +2 -2
- package/tools/scriptedPriceAuthority.d.ts.map +1 -1
- package/tools/scriptedPriceAuthority.js +0 -1
- package/tools/setup-zoe.d.ts +0 -5
- package/tools/setup-zoe.d.ts.map +1 -1
- package/src/contractFacet/reallocate.d.ts +0 -3
- package/src/contractFacet/reallocate.d.ts.map +0 -1
- package/src/contractFacet/reallocate.js +0 -94
- package/src/contractFacet/types-ambient.d.ts +0 -247
- package/src/contractFacet/types-ambient.js +0 -1
|
@@ -87,6 +87,7 @@ type MakeCloseLoanInvitation = (zcf: ZCF, config: LoanConfigWithBorrower) => Pro
|
|
|
87
87
|
* after adding.
|
|
88
88
|
*/
|
|
89
89
|
type MakeAddCollateralInvitation = (zcf: ZCF, config: LoanConfigWithBorrower) => Promise<Invitation>;
|
|
90
|
+
type Liquidate = (zcf: ZCF, config: LoanConfigWithBorrower) => void;
|
|
90
91
|
type MakeDebtCalculator = (debtCalculatorConfig: DebtCalculatorConfig) => any;
|
|
91
92
|
type CalcInterestFn = (oldDebt: Amount<'nat'>, interestRate: Ratio) => Amount<'nat'>;
|
|
92
93
|
type DebtCalculatorConfig = {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["types.js"],"names":[],"mappings":";;;;;;;sBACa,SAAS,OAAO,wBAAwB,EAAE,eAAe,CAAC;;;;;;;wBAU1D,QAAQ;;;;;;SAUP,KAAK;sBAGL,gBAAgB;;;;;oBAEhB,cAAc;oBAKd,cAAc;;;;;kBAEd,KAAK;oBAIL,OAAO,wBAAwB,EAAE,YAAY;eAE7C,KAAK;qBACL,KAAK;;;;;;gBAKL,OAAO;;;;;4BAMR,SAAS,GAAG,kBAAkB;;;;;;oBAQ7B,OAAO;;;;aAKP,MAAM,OAAO,KAAK,CAAC;;;;;2BAInB,cAAc,UAAU,CAAC;;;;;;;oBASzB,OAAO;;;;;2BAKP,cAAc,UAAU,CAAC;;;;;8BAO1B,oBAAoB,GAAG,wBAAwB;uCAM/C,oBAAoB,GAAG,iCAAiC;iCAM1D,GAAG,UACH,sBAAsB;gCAKtB,GAAG,UACH,SAAS,KACP,QAAQ,UAAU,CAAC;kCAKrB,GAAG,UACH,oBAAoB,KAClB,QAAQ,UAAU,CAAC;qCAKrB,GAAG,UACH,sBAAsB,KACpB,QAAQ,UAAU,CAAC;;;;;yCAQrB,GAAG,UACH,sBAAsB,KACpB,QAAQ,UAAU,CAAC;
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["types.js"],"names":[],"mappings":";;;;;;;sBACa,SAAS,OAAO,wBAAwB,EAAE,eAAe,CAAC;;;;;;;wBAU1D,QAAQ;;;;;;SAUP,KAAK;sBAGL,gBAAgB;;;;;oBAEhB,cAAc;oBAKd,cAAc;;;;;kBAEd,KAAK;oBAIL,OAAO,wBAAwB,EAAE,YAAY;eAE7C,KAAK;qBACL,KAAK;;;;;;gBAKL,OAAO;;;;;4BAMR,SAAS,GAAG,kBAAkB;;;;;;oBAQ7B,OAAO;;;;aAKP,MAAM,OAAO,KAAK,CAAC;;;;;2BAInB,cAAc,UAAU,CAAC;;;;;;;oBASzB,OAAO;;;;;2BAKP,cAAc,UAAU,CAAC;;;;;8BAO1B,oBAAoB,GAAG,wBAAwB;uCAM/C,oBAAoB,GAAG,iCAAiC;iCAM1D,GAAG,UACH,sBAAsB;gCAKtB,GAAG,UACH,SAAS,KACP,QAAQ,UAAU,CAAC;kCAKrB,GAAG,UACH,oBAAoB,KAClB,QAAQ,UAAU,CAAC;qCAKrB,GAAG,UACH,sBAAsB,KACpB,QAAQ,UAAU,CAAC;;;;;yCAQrB,GAAG,UACH,sBAAsB,KACpB,QAAQ,UAAU,CAAC;uBAKrB,GAAG,UACH,sBAAsB,KACpB,IAAI;iDAKN,oBAAoB;gCAKpB,OAAO,KAAK,CAAC,gBACb,KAAK,KACH,OAAO,KAAK,CAAC;;;;;;oBAKZ,cAAc;;;;kBAKd,OAAO,KAAK,CAAC;;;;oBAIb,cAAc;kBAId,KAAK;;;;oBACL,OAAO,wBAAwB,EAAE,YAAY;SAI7C,GAAG;wBAEH,+BAA+B;;;;;cAC/B,OAAO,wBAAwB,EAAE,SAAS;;;oBAM1C,OAAO;2BACP,cAAc,GAAG,CAAC;;sBAElB,OAAO,UAAU,CAAC;oBAClB,cAAc;oBACd,cAAc;kBACd,MAAM;oBACN,OAAO,wBAAwB,EAAE,YAAY;gBAC7C,OAAO;;;;;;;6BAMP,MAAM,QAAQ,UAAU,CAAC;;;;iCAKzB,MAAM,QAAQ,UAAU,CAAC;;;;;;;2BAIzB,MAAM,QAAQ,UAAU,CAAC;;;;iCAOzB,MAAM,OAAO,wBAAwB,EAAE,SAAS;;;;;qBAIhD,MAAM,SAAS,MAAM,CAAC;;;;+BAKtB,MAAM,MAAM"}
|
|
@@ -134,6 +134,13 @@
|
|
|
134
134
|
* @returns {Promise<Invitation>} addCollateralInvitation
|
|
135
135
|
*/
|
|
136
136
|
|
|
137
|
+
/**
|
|
138
|
+
* @callback Liquidate
|
|
139
|
+
* @param {ZCF} zcf
|
|
140
|
+
* @param {LoanConfigWithBorrower} config
|
|
141
|
+
* @returns {void}
|
|
142
|
+
*/
|
|
143
|
+
|
|
137
144
|
/**
|
|
138
145
|
* @callback MakeDebtCalculator
|
|
139
146
|
* @param {DebtCalculatorConfig} debtCalculatorConfig
|
|
@@ -11,20 +11,12 @@
|
|
|
11
11
|
* invitations for them, which when used to make an offer, will payout
|
|
12
12
|
* the specified amount of tokens.
|
|
13
13
|
*
|
|
14
|
-
* @
|
|
14
|
+
* @type {ContractStartFn<{getTokenIssuer: unknown}, {makeInvitation: unknown, getTokenIssuer: unknown}>}
|
|
15
15
|
*/
|
|
16
|
-
export
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
makeInvitation: (value?: bigint) => Promise<Invitation<R, A>>;
|
|
22
|
-
getTokenIssuer: () => Issuer<"nat">;
|
|
23
|
-
}>;
|
|
24
|
-
publicFacet: {
|
|
25
|
-
getTokenIssuer: () => Issuer<"nat">;
|
|
26
|
-
} & import("@endo/eventual-send").RemotableBrand<{}, {
|
|
27
|
-
getTokenIssuer: () => Issuer<"nat">;
|
|
28
|
-
}>;
|
|
16
|
+
export const start: ContractStartFn<{
|
|
17
|
+
getTokenIssuer: unknown;
|
|
18
|
+
}, {
|
|
19
|
+
makeInvitation: unknown;
|
|
20
|
+
getTokenIssuer: unknown;
|
|
29
21
|
}>;
|
|
30
22
|
//# sourceMappingURL=mintPayments.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"mintPayments.d.ts","sourceRoot":"","sources":["mintPayments.js"],"names":[],"mappings":"AAGA;;;;;;;;;;;;;;GAcG;AACH,
|
|
1
|
+
{"version":3,"file":"mintPayments.d.ts","sourceRoot":"","sources":["mintPayments.js"],"names":[],"mappings":"AAGA;;;;;;;;;;;;;;GAcG;AACH,oBAFU,gBAAgB;IAAC,cAAc,EAAE,OAAO,CAAA;CAAC,EAAE;IAAC,cAAc,EAAE,OAAO,CAAC;IAAC,cAAc,EAAE,OAAO,CAAA;CAAC,CAAC,CAyCtG"}
|
|
@@ -14,7 +14,7 @@ import { AmountMath } from '@agoric/ertp';
|
|
|
14
14
|
* invitations for them, which when used to make an offer, will payout
|
|
15
15
|
* the specified amount of tokens.
|
|
16
16
|
*
|
|
17
|
-
* @
|
|
17
|
+
* @type {ContractStartFn<{getTokenIssuer: unknown}, {makeInvitation: unknown, getTokenIssuer: unknown}>}
|
|
18
18
|
*/
|
|
19
19
|
const start = async zcf => {
|
|
20
20
|
// Create the internal token mint for a fungible digital asset. Note
|
|
@@ -15,12 +15,12 @@ export function start(zcf: ZCF): Promise<{
|
|
|
15
15
|
/** @param {OracleQuery} query */
|
|
16
16
|
query(query: OracleQuery): Promise<unknown>;
|
|
17
17
|
/** @param {OracleQuery} query */
|
|
18
|
-
makeQueryInvitation(query: OracleQuery): Promise<Invitation<
|
|
18
|
+
makeQueryInvitation(query: OracleQuery): Promise<Invitation<unknown, never>>;
|
|
19
19
|
} & import("@endo/eventual-send").RemotableBrand<{}, {
|
|
20
20
|
/** @param {OracleQuery} query */
|
|
21
21
|
query(query: OracleQuery): Promise<unknown>;
|
|
22
22
|
/** @param {OracleQuery} query */
|
|
23
|
-
makeQueryInvitation(query: OracleQuery): Promise<Invitation<
|
|
23
|
+
makeQueryInvitation(query: OracleQuery): Promise<Invitation<unknown, never>>;
|
|
24
24
|
}>;
|
|
25
25
|
}>;
|
|
26
26
|
//# sourceMappingURL=oracle.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"oracle.d.ts","sourceRoot":"","sources":["oracle.js"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"oracle.d.ts","sourceRoot":"","sources":["oracle.js"],"names":[],"mappings":"6BAsGc,WAAW,YAAY,CAAC;0BACxB,YAAY;AAhG1B;;;;GAIG;AACH,2BAFW,GAAG;;;;;;;QAkDV,iCAAiC;qBAArB,WAAW;QAevB,iCAAiC;mCAArB,WAAW;;QAfvB,iCAAiC;qBAArB,WAAW;QAevB,iCAAiC;mCAArB,WAAW;;GAuB1B"}
|
package/src/contracts/oracle.js
CHANGED
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
/* eslint @typescript-eslint/no-floating-promises: "warn" */
|
|
2
1
|
import { assert, Fail } from '@agoric/assert';
|
|
3
2
|
import { Far } from '@endo/marshal';
|
|
4
3
|
import { AmountMath } from '@agoric/ertp';
|
|
@@ -61,7 +60,6 @@ const start = async zcf => {
|
|
|
61
60
|
const publicFacet = Far('publicFacet', {
|
|
62
61
|
/** @param {OracleQuery} query */
|
|
63
62
|
async query(query) {
|
|
64
|
-
await null;
|
|
65
63
|
try {
|
|
66
64
|
assert(!revoked, revokedMsg);
|
|
67
65
|
const noFee = AmountMath.makeEmpty(feeBrand);
|
|
@@ -79,7 +77,6 @@ const start = async zcf => {
|
|
|
79
77
|
async makeQueryInvitation(query) {
|
|
80
78
|
/** @type {OfferHandler} */
|
|
81
79
|
const doQuery = async querySeat => {
|
|
82
|
-
await null;
|
|
83
80
|
try {
|
|
84
81
|
const fee = querySeat.getAmountAllocated('Fee', feeBrand);
|
|
85
82
|
const { requiredFee, reply } = await E(handler).onQuery(query, fee);
|
|
@@ -46,7 +46,12 @@ export function start(zcf: ZCF<{
|
|
|
46
46
|
*
|
|
47
47
|
* @param {Instance | string} [oracleKey]
|
|
48
48
|
*/
|
|
49
|
-
makeOracleInvitation: (oracleKey?: string | Instance | undefined) => Promise<Invitation<
|
|
49
|
+
makeOracleInvitation: (oracleKey?: string | Instance | undefined) => Promise<Invitation<{
|
|
50
|
+
admin: OracleAdmin<Price>;
|
|
51
|
+
invitationMakers: {
|
|
52
|
+
PushPrice: (price: ParsableNumber) => Promise<Invitation<void>>;
|
|
53
|
+
};
|
|
54
|
+
}, never>>;
|
|
50
55
|
/** @param {OracleKey} oracleKey */
|
|
51
56
|
deleteOracle: (oracleKey: OracleKey) => Promise<void>;
|
|
52
57
|
/**
|
|
@@ -66,7 +71,12 @@ export function start(zcf: ZCF<{
|
|
|
66
71
|
*
|
|
67
72
|
* @param {Instance | string} [oracleKey]
|
|
68
73
|
*/
|
|
69
|
-
makeOracleInvitation: (oracleKey?: string | Instance | undefined) => Promise<Invitation<
|
|
74
|
+
makeOracleInvitation: (oracleKey?: string | Instance | undefined) => Promise<Invitation<{
|
|
75
|
+
admin: OracleAdmin<Price>;
|
|
76
|
+
invitationMakers: {
|
|
77
|
+
PushPrice: (price: ParsableNumber) => Promise<Invitation<void>>;
|
|
78
|
+
};
|
|
79
|
+
}, never>>;
|
|
70
80
|
/** @param {OracleKey} oracleKey */
|
|
71
81
|
deleteOracle: (oracleKey: OracleKey) => Promise<void>;
|
|
72
82
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"priceAggregator.d.ts","sourceRoot":"","sources":["priceAggregator.js"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"priceAggregator.d.ts","sourceRoot":"","sources":["priceAggregator.js"],"names":[],"mappings":"6BAoCc,MAAM,GAAG,MAAM,GAAG,MAAM;oCAEzB,SAAS,cAAc,GAAG;IAAE,IAAI,EAAE,cAAc,CAAA;CAAE,CAAC;oBAGlD,cAAc,GAAG,KAAK;sCAmlBtB,WAAW,YAAY,CAAC;AA9kBtC;;;;;;;;;;;;;;;;;;;GAmBG;AACH;WAZU,OAAO,wBAAwB,EAAE,YAAY;mBACrC,MAAM;aACZ,MAAM,KAAK,CAAC;cACX,MAAM,KAAK,CAAC;kBACR,OAAO,KAAK,CAAC;;gBAGf,UAAU;;iBAET,KAAK,WAAW,CAAC;;;QAiX7B;;;;;;;;;WASG;;mBAY4B,YAAY,KAAK,CAAC;;mCAAwC,cAAc,KAAK,QAAQ,WAAW,IAAI,CAAC,CAAC;;;QA0CrI,mCAAmC;kCAAvB,SAAS;QAarB;;;;WAIG;yGADU,QAAQ,YAAY,KAAK,CAAC,CAAC;;QA/ExC;;;;;;;;;WASG;;mBAY4B,YAAY,KAAK,CAAC;;mCAAwC,cAAc,KAAK,QAAQ,WAAW,IAAI,CAAC,CAAC;;;QA0CrI,mCAAmC;kCAAvB,SAAS;QAarB;;;;WAIG;yGADU,QAAQ,YAAY,KAAK,CAAC,CAAC;;;;;QAmHxC,sBAAsB;;;;;QAAtB,sBAAsB;;;GAOzB"}
|
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
/// <reference types="@agoric/time/src/types.d.ts" />
|
|
1
|
+
/// <reference path="../../../time/src/types.d.ts" />
|
|
3
2
|
|
|
4
3
|
import { Fail, q } from '@agoric/assert';
|
|
5
4
|
import { AmountMath, AssetKind, makeIssuerKit } from '@agoric/ertp';
|
|
@@ -458,7 +457,6 @@ const start = async (zcf, privateArgs) => {
|
|
|
458
457
|
seat,
|
|
459
458
|
{ notifier: oracleNotifier, scaleValueOut = 1 } = {},
|
|
460
459
|
) => {
|
|
461
|
-
seat.exit();
|
|
462
460
|
const admin = await creatorFacet.initOracle(oracleKey);
|
|
463
461
|
const invitationMakers = Far('invitation makers', {
|
|
464
462
|
/** @param {ParsableNumber} price */
|
|
@@ -470,6 +468,7 @@ const start = async (zcf, privateArgs) => {
|
|
|
470
468
|
}, 'PushPrice');
|
|
471
469
|
},
|
|
472
470
|
});
|
|
471
|
+
seat.exit();
|
|
473
472
|
|
|
474
473
|
if (oracleNotifier) {
|
|
475
474
|
pushFromOracle(oracleNotifier, scaleValueOut, r =>
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export function prepare(zcf: ZCF<ScaledPriceAuthorityOpts>, privateArgs: object, baggage: MapStore<string,
|
|
1
|
+
export function prepare(zcf: ZCF<ScaledPriceAuthorityOpts>, privateArgs: object, baggage: MapStore<string, unknown>): Promise<{
|
|
2
2
|
publicFacet: {
|
|
3
3
|
getPriceAuthority: () => Promise<PriceAuthority>;
|
|
4
4
|
} & import("@endo/eventual-send").RemotableBrand<{}, {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"scaledPriceAuthority.d.ts","sourceRoot":"","sources":["scaledPriceAuthority.js"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"scaledPriceAuthority.d.ts","sourceRoot":"","sources":["scaledPriceAuthority.js"],"names":[],"mappings":"AAgCO,6BAJI,IAAI,wBAAwB,CAAC,eAC7B,MAAM;;;;;;GAyDhB;;0BAzEa,KAAK,cAAc,CAAC;;;;aACpB,KAAK;;;;cACL,KAAK"}
|
|
@@ -30,7 +30,6 @@ import { provideQuoteMint } from '../contractSupport/priceAuthorityQuoteMint.js'
|
|
|
30
30
|
* @param {object} privateArgs
|
|
31
31
|
* @param {import('@agoric/vat-data').Baggage} baggage
|
|
32
32
|
*/
|
|
33
|
-
// 'prepare' is deprecated but still supported
|
|
34
33
|
export const prepare = async (zcf, privateArgs, baggage) => {
|
|
35
34
|
const quoteMint = provideQuoteMint(baggage);
|
|
36
35
|
|
|
@@ -86,4 +85,3 @@ export const prepare = async (zcf, privateArgs, baggage) => {
|
|
|
86
85
|
);
|
|
87
86
|
return harden({ publicFacet });
|
|
88
87
|
};
|
|
89
|
-
harden(prepare);
|
|
@@ -24,7 +24,7 @@ export function start(zcf: ZCF<{
|
|
|
24
24
|
pricePerItem: Amount<'nat'>;
|
|
25
25
|
}>): {
|
|
26
26
|
creatorFacet: SellItemsCreatorFacet;
|
|
27
|
-
creatorInvitation: Promise<Invitation<
|
|
27
|
+
creatorInvitation: Promise<Invitation<string, never>>;
|
|
28
28
|
publicFacet: SellItemsPublicFacet;
|
|
29
29
|
};
|
|
30
30
|
//# sourceMappingURL=sellItems.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sellItems.d.ts","sourceRoot":"","sources":["sellItems.js"],"names":[],"mappings":"AAkBA;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH;kBAF8B,OAAO,KAAK,CAAC;;;;;
|
|
1
|
+
{"version":3,"file":"sellItems.d.ts","sourceRoot":"","sources":["sellItems.js"],"names":[],"mappings":"AAkBA;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH;kBAF8B,OAAO,KAAK,CAAC;;;;;EAwH1C"}
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
/* eslint @typescript-eslint/no-floating-promises: "warn" */
|
|
2
1
|
import { Far } from '@endo/marshal';
|
|
3
2
|
import { Nat } from '@endo/nat';
|
|
4
3
|
import { AmountMath } from '@agoric/ertp';
|
|
@@ -12,6 +11,7 @@ import {
|
|
|
12
11
|
defaultAcceptanceMsg,
|
|
13
12
|
assertProposalShape,
|
|
14
13
|
assertNatAssetKind,
|
|
14
|
+
atomicRearrange,
|
|
15
15
|
} from '../contractSupport/index.js';
|
|
16
16
|
|
|
17
17
|
const { Fail } = assert;
|
|
@@ -107,7 +107,8 @@ const start = zcf => {
|
|
|
107
107
|
Fail`More money (${totalCost}) is required to buy these items`;
|
|
108
108
|
|
|
109
109
|
// Reallocate.
|
|
110
|
-
|
|
110
|
+
atomicRearrange(
|
|
111
|
+
zcf,
|
|
111
112
|
harden([
|
|
112
113
|
[buyerSeat, sellerSeat, { Money: providedMoney }],
|
|
113
114
|
[sellerSeat, buyerSeat, { Items: wantedItems }],
|
|
@@ -21,13 +21,13 @@
|
|
|
21
21
|
*/
|
|
22
22
|
export function start(zcf: ZCF): {
|
|
23
23
|
publicFacet: {
|
|
24
|
-
makeInvitation: () => Promise<Invitation<
|
|
24
|
+
makeInvitation: () => Promise<Invitation<unknown, never>>;
|
|
25
25
|
getNotifier: () => Notifier<{
|
|
26
26
|
buys: any;
|
|
27
27
|
sells: any;
|
|
28
28
|
}>;
|
|
29
29
|
} & import("@endo/eventual-send").RemotableBrand<{}, {
|
|
30
|
-
makeInvitation: () => Promise<Invitation<
|
|
30
|
+
makeInvitation: () => Promise<Invitation<unknown, never>>;
|
|
31
31
|
getNotifier: () => Notifier<{
|
|
32
32
|
buys: any;
|
|
33
33
|
sells: any;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export function makeInstanceRecordStorage(baggage: MapStore<string,
|
|
1
|
+
export function makeInstanceRecordStorage(baggage: MapStore<string, unknown>): (ir: InstanceRecord) => InstanceState;
|
|
2
2
|
//# sourceMappingURL=instanceRecordStorage.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"instanceRecordStorage.d.ts","sourceRoot":"","sources":["instanceRecordStorage.js"],"names":[],"mappings":"AA8BO,
|
|
1
|
+
{"version":3,"file":"instanceRecordStorage.d.ts","sourceRoot":"","sources":["instanceRecordStorage.js"],"names":[],"mappings":"AA8BO,oFAFW,cAAc,KAAK,aAAa,CAqFjD"}
|
package/src/internal-types.d.ts
CHANGED
|
@@ -22,7 +22,7 @@ type ZoeSeatAdminKit = {
|
|
|
22
22
|
/**
|
|
23
23
|
* Make the Zoe seat admin, user seat and a notifier
|
|
24
24
|
*/
|
|
25
|
-
type MakeZoeSeatAdminKit = (initialAllocation: Allocation, instanceAdminHelper: InstanceAdminHelper, proposal: ProposalRecord, withdrawFacet: WithdrawFacet, exitObj: ERef<ExitObj>, offerResult?: ERef<unknown>, baggage: MapStore<string,
|
|
25
|
+
type MakeZoeSeatAdminKit = (initialAllocation: Allocation, instanceAdminHelper: InstanceAdminHelper, proposal: ProposalRecord, withdrawFacet: WithdrawFacet, exitObj: ERef<ExitObj>, offerResult?: ERef<unknown>, baggage: MapStore<string, unknown>) => ZoeSeatAdminKit;
|
|
26
26
|
type ZoeSeatAdminExit = (completion?: Completion) => void;
|
|
27
27
|
type ZoeSeatAdmin = {
|
|
28
28
|
replaceAllocation: (allocation: Allocation) => void;
|
|
@@ -114,7 +114,7 @@ type ZCFRoot = {
|
|
|
114
114
|
};
|
|
115
115
|
type ExecuteContractResult = {
|
|
116
116
|
creatorFacet: object;
|
|
117
|
-
creatorInvitation
|
|
117
|
+
creatorInvitation: Promise<Invitation>;
|
|
118
118
|
publicFacet: object;
|
|
119
119
|
handleOfferObj: HandleOfferObj;
|
|
120
120
|
};
|
|
@@ -150,7 +150,7 @@ type ZcfMintReallocator = {
|
|
|
150
150
|
* The SeatManager holds the active zcfSeats and can reallocate and
|
|
151
151
|
* make new zcfSeats.
|
|
152
152
|
*/
|
|
153
|
-
type CreateSeatManager = (zoeInstanceAdmin: ERef<ZoeInstanceAdmin>, getAssetKindByBrand: GetAssetKindByBrand, shutdownWithFailure: ShutdownWithFailure, zcfBaggage: MapStore<string,
|
|
153
|
+
type CreateSeatManager = (zoeInstanceAdmin: ERef<ZoeInstanceAdmin>, getAssetKindByBrand: GetAssetKindByBrand, shutdownWithFailure: ShutdownWithFailure, zcfBaggage: MapStore<string, unknown>) => {
|
|
154
154
|
seatManager: ZcfSeatManager;
|
|
155
155
|
zcfMintReallocator: ZcfMintReallocator;
|
|
156
156
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"internal-types.d.ts","sourceRoot":"","sources":["internal-types.js"],"names":[],"mappings":";cAIc,cAAc;uBACd,UAAU;gBACV,UAAU;gBACV,MAAM;;;;;qCAOT,UAAU,KACR,qBAAqB;;mCAKR,UAAU,KAAK,qBAAqB;;;qCAKjC,YAAY,KAAK,IAAI;8BACrB,YAAY,KAAK,OAAO;;;cAKvC,QAAQ;kBACR,YAAY;;;;;+CAMf,UAAU,uBACV,mBAAmB,YACnB,cAAc,iBACd,aAAa,WACb,KAAK,OAAO,CAAC,gBACb,KAAK,OAAO,CAAC,
|
|
1
|
+
{"version":3,"file":"internal-types.d.ts","sourceRoot":"","sources":["internal-types.js"],"names":[],"mappings":"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"}
|
package/src/internal-types.js
CHANGED
|
@@ -204,7 +204,7 @@
|
|
|
204
204
|
/**
|
|
205
205
|
* @typedef {object} ExecuteContractResult
|
|
206
206
|
* @property {object} creatorFacet
|
|
207
|
-
* @property {Promise<Invitation>}
|
|
207
|
+
* @property {Promise<Invitation>} creatorInvitation
|
|
208
208
|
* @property {object} publicFacet
|
|
209
209
|
* @property {HandleOfferObj} handleOfferObj
|
|
210
210
|
*/
|
package/src/issuerStorage.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export function provideIssuerStorage(zcfBaggage: MapStore<string,
|
|
1
|
+
export function provideIssuerStorage(zcfBaggage: MapStore<string, unknown>): {
|
|
2
2
|
storeIssuerKeywordRecord: (uncleanIssuerKeywordRecord: IssuerKeywordRecord) => Promise<{
|
|
3
3
|
issuers: IssuerKeywordRecord;
|
|
4
4
|
brands: BrandKeywordRecord;
|
package/src/makeHandle.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export function defineDurableHandle<H extends string>(baggage: MapStore<string,
|
|
1
|
+
export function defineDurableHandle<H extends string>(baggage: MapStore<string, unknown>, handleType: H): H extends "Instance" ? () => Instance : () => Handle<H>;
|
|
2
2
|
export function makeHandle<H extends string>(handleType: H): H extends "Instance" ? Instance : Handle<H>;
|
|
3
3
|
export type Baggage = import('@agoric/vat-data').Baggage;
|
|
4
4
|
//# sourceMappingURL=makeHandle.d.ts.map
|
package/src/makeHandle.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"makeHandle.d.ts","sourceRoot":"","sources":["makeHandle.js"],"names":[],"mappings":"AAkBO,
|
|
1
|
+
{"version":3,"file":"makeHandle.d.ts","sourceRoot":"","sources":["makeHandle.js"],"names":[],"mappings":"AAkBO,uIAFmC,QAAQ,mBAajD;AAUM,yGAKN;sBAlCa,OAAO,kBAAkB,EAAE,OAAO"}
|
package/src/typeGuards.d.ts
CHANGED
|
@@ -18,151 +18,53 @@ export namespace TermsShape {
|
|
|
18
18
|
export namespace InstanceRecordShape {
|
|
19
19
|
export { InstallationShape as installation };
|
|
20
20
|
export { InstanceHandleShape as instance };
|
|
21
|
-
export
|
|
21
|
+
export const terms: import("@endo/patterns").Matcher;
|
|
22
22
|
}
|
|
23
|
-
export const HandleI: import("@endo/patterns").InterfaceGuard
|
|
23
|
+
export const HandleI: import("@endo/patterns").InterfaceGuard;
|
|
24
24
|
export function makeHandleShape(name: any): import("@endo/patterns").Matcher;
|
|
25
25
|
export const TimerShape: import("@endo/patterns").Matcher;
|
|
26
26
|
export namespace FullProposalShape {
|
|
27
27
|
export { AmountPatternKeywordRecordShape as want };
|
|
28
28
|
export { AmountKeywordRecordShape as give };
|
|
29
|
-
export
|
|
29
|
+
export const exit: import("@endo/patterns").Matcher;
|
|
30
30
|
}
|
|
31
31
|
/** @see {Proposal} type */
|
|
32
32
|
export const ProposalShape: import("@endo/patterns").Matcher;
|
|
33
|
-
export const EmptyProposalShape: import("@endo/patterns").Matcher;
|
|
34
33
|
export function isOnDemandExitRule(exit: any): boolean;
|
|
35
34
|
export function isWaivedExitRule(exit: ExitRule): exit is WaivedExitRule;
|
|
36
35
|
export function isAfterDeadlineExitRule(exit: ExitRule): exit is AfterDeadlineExitRule;
|
|
37
36
|
export const InvitationElementShape: import("@endo/patterns").Matcher;
|
|
38
|
-
export const OfferHandlerI: import("@endo/patterns").InterfaceGuard
|
|
39
|
-
handle: import("@endo/patterns").MethodGuard;
|
|
40
|
-
}>;
|
|
37
|
+
export const OfferHandlerI: import("@endo/patterns").InterfaceGuard;
|
|
41
38
|
export const SeatHandleAllocationsShape: import("@endo/patterns").Matcher;
|
|
42
39
|
export const ZoeMintShape: import("@endo/patterns").Matcher;
|
|
43
|
-
export const ZoeMintI: import("@endo/patterns").InterfaceGuard
|
|
44
|
-
|
|
45
|
-
mintAndEscrow: import("@endo/patterns").MethodGuard;
|
|
46
|
-
withdrawAndBurn: import("@endo/patterns").MethodGuard;
|
|
47
|
-
}>;
|
|
48
|
-
export const ZcfMintI: import("@endo/patterns").InterfaceGuard<{
|
|
49
|
-
getIssuerRecord: import("@endo/patterns").MethodGuard;
|
|
50
|
-
mintGains: import("@endo/patterns").MethodGuard;
|
|
51
|
-
burnLosses: import("@endo/patterns").MethodGuard;
|
|
52
|
-
}>;
|
|
40
|
+
export const ZoeMintI: import("@endo/patterns").InterfaceGuard;
|
|
41
|
+
export const ZcfMintI: import("@endo/patterns").InterfaceGuard;
|
|
53
42
|
export const FeeMintAccessShape: import("@endo/patterns").Matcher;
|
|
54
|
-
export const ExitObjectI: import("@endo/patterns").InterfaceGuard
|
|
55
|
-
exit: import("@endo/patterns").MethodGuard;
|
|
56
|
-
}>;
|
|
43
|
+
export const ExitObjectI: import("@endo/patterns").InterfaceGuard;
|
|
57
44
|
export const ExitObjectShape: import("@endo/patterns").Matcher;
|
|
58
45
|
export const InstanceAdminShape: import("@endo/patterns").Matcher;
|
|
59
|
-
export const InstanceAdminI: import("@endo/patterns").InterfaceGuard
|
|
60
|
-
makeInvitation: import("@endo/patterns").MethodGuard;
|
|
61
|
-
saveIssuer: import("@endo/patterns").MethodGuard;
|
|
62
|
-
makeNoEscrowSeat: import("@endo/patterns").MethodGuard;
|
|
63
|
-
exitAllSeats: import("@endo/patterns").MethodGuard;
|
|
64
|
-
failAllSeats: import("@endo/patterns").MethodGuard;
|
|
65
|
-
exitSeat: import("@endo/patterns").MethodGuard;
|
|
66
|
-
failSeat: import("@endo/patterns").MethodGuard;
|
|
67
|
-
makeZoeMint: import("@endo/patterns").MethodGuard;
|
|
68
|
-
registerFeeMint: import("@endo/patterns").MethodGuard;
|
|
69
|
-
replaceAllocations: import("@endo/patterns").MethodGuard;
|
|
70
|
-
stopAcceptingOffers: import("@endo/patterns").MethodGuard;
|
|
71
|
-
setOfferFilter: import("@endo/patterns").MethodGuard;
|
|
72
|
-
getOfferFilter: import("@endo/patterns").MethodGuard;
|
|
73
|
-
getExitSubscriber: import("@endo/patterns").MethodGuard;
|
|
74
|
-
isBlocked: import("@endo/patterns").MethodGuard;
|
|
75
|
-
}>;
|
|
46
|
+
export const InstanceAdminI: import("@endo/patterns").InterfaceGuard;
|
|
76
47
|
export namespace InstanceStorageManagerIKit {
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
getBrands: import("@endo/patterns").MethodGuard;
|
|
81
|
-
getInstallation: import("@endo/patterns").MethodGuard;
|
|
82
|
-
getInvitationIssuer: import("@endo/patterns").MethodGuard;
|
|
83
|
-
saveIssuer: import("@endo/patterns").MethodGuard;
|
|
84
|
-
makeZoeMint: import("@endo/patterns").MethodGuard;
|
|
85
|
-
registerFeeMint: import("@endo/patterns").MethodGuard;
|
|
86
|
-
getInstanceRecord: import("@endo/patterns").MethodGuard;
|
|
87
|
-
getIssuerRecords: import("@endo/patterns").MethodGuard;
|
|
88
|
-
getWithdrawFacet: import("@endo/patterns").MethodGuard;
|
|
89
|
-
initInstanceAdmin: import("@endo/patterns").MethodGuard;
|
|
90
|
-
deleteInstanceAdmin: import("@endo/patterns").MethodGuard;
|
|
91
|
-
makeInvitation: import("@endo/patterns").MethodGuard;
|
|
92
|
-
getRoot: import("@endo/patterns").MethodGuard;
|
|
93
|
-
getAdminNode: import("@endo/patterns").MethodGuard;
|
|
94
|
-
}>;
|
|
95
|
-
let withdrawFacet: import("@endo/patterns").InterfaceGuard<{
|
|
96
|
-
withdrawPayments: import("@endo/patterns").MethodGuard;
|
|
97
|
-
}>;
|
|
98
|
-
let helpers: import("@endo/patterns").InterfaceGuard<{
|
|
99
|
-
wrapIssuerKitWithZoeMint: import("@endo/patterns").MethodGuard;
|
|
100
|
-
}>;
|
|
48
|
+
const instanceStorageManager: import("@endo/patterns").InterfaceGuard;
|
|
49
|
+
const withdrawFacet: import("@endo/patterns").InterfaceGuard;
|
|
50
|
+
const helpers: import("@endo/patterns").InterfaceGuard;
|
|
101
51
|
}
|
|
102
52
|
export const BundleCapShape: import("@endo/patterns").Matcher;
|
|
103
53
|
export const BundleShape: import("@endo/patterns").Matcher;
|
|
104
54
|
export const UnwrappedInstallationShape: import("@endo/patterns").Matcher;
|
|
105
55
|
export namespace ZoeStorageManagerIKit {
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
getInstallation: import("@endo/patterns").MethodGuard;
|
|
111
|
-
getInvitationIssuer: import("@endo/patterns").MethodGuard;
|
|
112
|
-
getBundleIDFromInstallation: import("@endo/patterns").MethodGuard;
|
|
113
|
-
installBundle: import("@endo/patterns").MethodGuard;
|
|
114
|
-
installBundleID: import("@endo/patterns").MethodGuard;
|
|
115
|
-
getPublicFacet: import("@endo/patterns").MethodGuard;
|
|
116
|
-
getOfferFilter: import("@endo/patterns").MethodGuard;
|
|
117
|
-
getProposalShapeForInvitation: import("@endo/patterns").MethodGuard;
|
|
118
|
-
}>;
|
|
119
|
-
let makeOfferAccess: import("@endo/patterns").InterfaceGuard<{
|
|
120
|
-
getAssetKindByBrand: import("@endo/patterns").MethodGuard;
|
|
121
|
-
getInstanceAdmin: import("@endo/patterns").MethodGuard;
|
|
122
|
-
getProposalShapeForInvitation: import("@endo/patterns").MethodGuard;
|
|
123
|
-
getInvitationIssuer: import("@endo/patterns").MethodGuard;
|
|
124
|
-
depositPayments: import("@endo/patterns").MethodGuard;
|
|
125
|
-
}>;
|
|
126
|
-
let startInstanceAccess: import("@endo/patterns").InterfaceGuard<{
|
|
127
|
-
makeZoeInstanceStorageManager: import("@endo/patterns").MethodGuard;
|
|
128
|
-
unwrapInstallation: import("@endo/patterns").MethodGuard;
|
|
129
|
-
}>;
|
|
130
|
-
let invitationIssuerAccess: import("@endo/patterns").InterfaceGuard<{
|
|
131
|
-
getInvitationIssuer: import("@endo/patterns").MethodGuard;
|
|
132
|
-
}>;
|
|
56
|
+
const zoeServiceDataAccess: import("@endo/patterns").InterfaceGuard;
|
|
57
|
+
const makeOfferAccess: import("@endo/patterns").InterfaceGuard;
|
|
58
|
+
const startInstanceAccess: import("@endo/patterns").InterfaceGuard;
|
|
59
|
+
const invitationIssuerAccess: import("@endo/patterns").InterfaceGuard;
|
|
133
60
|
}
|
|
134
|
-
export const ZoeServiceI: import("@endo/patterns").InterfaceGuard
|
|
135
|
-
|
|
136
|
-
installBundleID: import("@endo/patterns").MethodGuard;
|
|
137
|
-
startInstance: import("@endo/patterns").MethodGuard;
|
|
138
|
-
offer: import("@endo/patterns").MethodGuard;
|
|
139
|
-
getOfferFilter: import("@endo/patterns").MethodGuard;
|
|
140
|
-
getInvitationIssuer: import("@endo/patterns").MethodGuard;
|
|
141
|
-
getFeeIssuer: import("@endo/patterns").MethodGuard;
|
|
142
|
-
getBrands: import("@endo/patterns").MethodGuard;
|
|
143
|
-
getIssuers: import("@endo/patterns").MethodGuard;
|
|
144
|
-
getPublicFacet: import("@endo/patterns").MethodGuard;
|
|
145
|
-
getTerms: import("@endo/patterns").MethodGuard;
|
|
146
|
-
getInstallationForInstance: import("@endo/patterns").MethodGuard;
|
|
147
|
-
getBundleIDFromInstallation: import("@endo/patterns").MethodGuard;
|
|
148
|
-
getInstallation: import("@endo/patterns").MethodGuard;
|
|
149
|
-
getInstance: import("@endo/patterns").MethodGuard;
|
|
150
|
-
getConfiguration: import("@endo/patterns").MethodGuard;
|
|
151
|
-
getInvitationDetails: import("@endo/patterns").MethodGuard;
|
|
152
|
-
getProposalShapeForInvitation: import("@endo/patterns").MethodGuard;
|
|
153
|
-
}>;
|
|
154
|
-
export const AdminFacetI: import("@endo/patterns").InterfaceGuard<{
|
|
155
|
-
getVatShutdownPromise: import("@endo/patterns").MethodGuard;
|
|
156
|
-
restartContract: import("@endo/patterns").MethodGuard;
|
|
157
|
-
upgradeContract: import("@endo/patterns").MethodGuard;
|
|
158
|
-
}>;
|
|
61
|
+
export const ZoeServiceI: import("@endo/patterns").InterfaceGuard;
|
|
62
|
+
export const AdminFacetI: import("@endo/patterns").InterfaceGuard;
|
|
159
63
|
export const SeatDataShape: import("@endo/patterns").Matcher;
|
|
160
|
-
export const HandleOfferI: import("@endo/patterns").InterfaceGuard
|
|
161
|
-
handleOffer: import("@endo/patterns").MethodGuard;
|
|
162
|
-
}>;
|
|
64
|
+
export const HandleOfferI: import("@endo/patterns").InterfaceGuard;
|
|
163
65
|
export namespace PriceQuoteShape {
|
|
164
66
|
export { AmountShape as quoteAmount };
|
|
165
|
-
export
|
|
67
|
+
export const quotePayment: any;
|
|
166
68
|
}
|
|
167
|
-
import { AmountShape } from
|
|
69
|
+
import { AmountShape } from "@agoric/ertp/src/typeGuards";
|
|
168
70
|
//# sourceMappingURL=typeGuards.d.ts.map
|
package/src/typeGuards.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"typeGuards.d.ts","sourceRoot":"","sources":["typeGuards.js"],"names":[],"mappings":"AAgBA,4DAAuC;AAEvC,qEAAqE;AACrE,+DAAyD;AACzD,mEAAiE;AACjE,iEAA6D;AAC7D,yDAA6C;AAE7C,wEAA8E;AAC9E,+EAGE;AACF,0EAGE;AACF,wEAA8E;AAC9E,yEAGE;AACF,uEAA4E;AAE5E,iEAOE;;;;;;;;;;AAaF,
|
|
1
|
+
{"version":3,"file":"typeGuards.d.ts","sourceRoot":"","sources":["typeGuards.js"],"names":[],"mappings":"AAgBA,4DAAuC;AAEvC,qEAAqE;AACrE,+DAAyD;AACzD,mEAAiE;AACjE,iEAA6D;AAC7D,yDAA6C;AAE7C,wEAA8E;AAC9E,+EAGE;AACF,0EAGE;AACF,wEAA8E;AAC9E,yEAGE;AACF,uEAA4E;AAE5E,iEAOE;;;;;;;;;;AAaF,8DAAiD;AAE1C,6EAA4D;AACnE,0DAAmD;;;;;;AA0BnD,2BAA2B;AAC3B,6DAAsE;AAE/D,uDAGN;AAMM,uCAHI,QAAQ,0BAMlB;AAMM,8CAHI,QAAQ,iCAMlB;AAED,sEAKG;AAEH,oEAEG;AAEH,0EAKE;AAEF,4DAAmD;AACnD,+DAIG;AAEH,+DASG;AAEH,kEAA+D;AAE/D,kEAEG;AAEH,+DAAsD;AACtD,kEAA+D;AAC/D,qEAiCG;;;;;;AAiDH,8DAAuD;AACvD,2DAGE;AAEF,0EAUE;;;;;;;AA2DF,kEA6CG;AAEH,kEAIG;AAEH,6DASE;AAEF,mEAKG"}
|
package/src/typeGuards.js
CHANGED
|
@@ -90,12 +90,6 @@ export const FullProposalShape = harden({
|
|
|
90
90
|
/** @see {Proposal} type */
|
|
91
91
|
export const ProposalShape = M.splitRecord({}, FullProposalShape, {});
|
|
92
92
|
|
|
93
|
-
export const EmptyProposalShape = M.splitRecord({
|
|
94
|
-
give: {},
|
|
95
|
-
want: {},
|
|
96
|
-
exit: { onDemand: null },
|
|
97
|
-
});
|
|
98
|
-
|
|
99
93
|
export const isOnDemandExitRule = exit => {
|
|
100
94
|
const [exitKey] = Object.keys(exit);
|
|
101
95
|
return exitKey === 'onDemand';
|
|
@@ -224,7 +218,7 @@ export const InstanceStorageManagerIKit = harden({
|
|
|
224
218
|
InstanceHandleShape,
|
|
225
219
|
M.remotable('instanceAdmin'),
|
|
226
220
|
).returns(M.promise()),
|
|
227
|
-
deleteInstanceAdmin: M.call(
|
|
221
|
+
deleteInstanceAdmin: M.call(InstanceAdminI).returns(),
|
|
228
222
|
makeInvitation: M.call(InvitationHandleShape, M.string())
|
|
229
223
|
.optional(M.record(), M.pattern())
|
|
230
224
|
.returns(PaymentShape),
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
export namespace defaultFeeIssuerConfig {
|
|
2
|
-
|
|
3
|
-
|
|
2
|
+
const name: "ZDEFAULT";
|
|
3
|
+
const assetKind: "nat";
|
|
4
4
|
namespace displayInfo {
|
|
5
|
-
export
|
|
6
|
-
|
|
5
|
+
export const decimalPlaces: number;
|
|
6
|
+
const assetKind_1: "nat";
|
|
7
7
|
export { assetKind_1 as assetKind };
|
|
8
8
|
}
|
|
9
9
|
}
|
|
@@ -12,7 +12,7 @@ export namespace defaultFeeIssuerConfig {
|
|
|
12
12
|
* @param {FeeIssuerConfig} feeIssuerConfig
|
|
13
13
|
* @param {ShutdownWithFailure} shutdownZoeVat
|
|
14
14
|
*/
|
|
15
|
-
export function prepareFeeMint(zoeBaggage: MapStore<string,
|
|
15
|
+
export function prepareFeeMint(zoeBaggage: MapStore<string, unknown>, feeIssuerConfig: FeeIssuerConfig, shutdownZoeVat: ShutdownWithFailure): {
|
|
16
16
|
feeMint: {
|
|
17
17
|
getFeeIssuerKit(allegedFeeMintAccess: any): any;
|
|
18
18
|
getFeeIssuer(): any;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"feeMint.d.ts","sourceRoot":"","sources":["feeMint.js"],"names":[],"mappings":";;;;;;;;;AA2BA;;;;GAIG;AACH,
|
|
1
|
+
{"version":3,"file":"feeMint.d.ts","sourceRoot":"","sources":["feeMint.js"],"names":[],"mappings":";;;;;;;;;AA2BA;;;;GAIG;AACH,uFAHW,eAAe,kBACf,mBAAmB;;;;;;;;;;;;;;GAsD7B"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export function makeInstallationStorage(getBundleCapForID: GetBundleCapForID, zoeBaggage: MapStore<string,
|
|
1
|
+
export function makeInstallationStorage(getBundleCapForID: GetBundleCapForID, zoeBaggage: MapStore<string, unknown>): {
|
|
2
2
|
installBundle(allegedBundle: any, bundleLabel: any): any;
|
|
3
3
|
installBundleID(bundleID: any, bundleLabel?: any): Promise<Installation<any>>;
|
|
4
4
|
unwrapInstallation(installation: any): {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export function makeInstanceAdminStorage(baggage: MapStore<string,
|
|
1
|
+
export function makeInstanceAdminStorage(baggage: MapStore<string, unknown>): {
|
|
2
2
|
accessor: {
|
|
3
3
|
getPublicFacet(instance: any): any;
|
|
4
4
|
getBrands(instance: any): any;
|
|
@@ -27,7 +27,7 @@ export function makeInstanceAdminStorage(baggage: MapStore<string, any>): {
|
|
|
27
27
|
deleteInstanceAdmin(instance: any): any;
|
|
28
28
|
};
|
|
29
29
|
}>;
|
|
30
|
-
export function makeInstanceAdminMaker(zoeBaggage: MapStore<string,
|
|
30
|
+
export function makeInstanceAdminMaker(zoeBaggage: MapStore<string, unknown>, seatHandleToZoeSeatAdmin: WeakMapStore<SeatHandle, ZoeSeatAdmin>): (instanceHandle: any, zoeInstanceStorageManager: any, adminNode: any) => import("@agoric/vat-data/src/types.js").KindFacet<{
|
|
31
31
|
getPublicFacet: ({ state }: {
|
|
32
32
|
state: any;
|
|
33
33
|
}) => any;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"instanceAdminStorage.d.ts","sourceRoot":"","sources":["instanceAdminStorage.js"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"instanceAdminStorage.d.ts","sourceRoot":"","sources":["instanceAdminStorage.js"],"names":[],"mappings":"AAmDO;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA0DN;AA0JM,wGAFI,aAAa,UAAU,EAAE,YAAY,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAwChD;6BAvDY,SAAS;IACrB,WAAe,EAAE,OAAO,CAAC;IACzB,eAAmB,EAAE,OAAO,CAAC;CAC1B,CAAC;2BACQ;IACZ,kBAAsB,EAAE,MAAM,EAAE,CAAC;CAC9B;oBACS,YAAY,GAAG,cAAc;4BAC7B;IACZ,KAAS,EAAE,KAAK,CAAC;CACd"}
|