@openzeppelin/adapter-stellar 1.0.0 → 1.1.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/dist/index.cjs +40 -7
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts.map +1 -1
- package/dist/index.d.mts.map +1 -1
- package/dist/index.mjs +40 -8
- package/dist/index.mjs.map +1 -1
- package/package.json +16 -9
- package/src/index.ts +20 -0
- package/src/mapping/field-generator.ts +1 -1
- package/src/wallet/components/account/AccountDisplay.tsx +13 -6
package/dist/index.cjs
CHANGED
|
@@ -28,6 +28,7 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
|
|
|
28
28
|
const require_config = require('./config.cjs');
|
|
29
29
|
const require_metadata = require('./metadata.cjs');
|
|
30
30
|
const require_networks = require('./networks-DgUFSTiC.cjs');
|
|
31
|
+
let _openzeppelin_ui_components = require("@openzeppelin/ui-components");
|
|
31
32
|
let _openzeppelin_ui_types = require("@openzeppelin/ui-types");
|
|
32
33
|
let _openzeppelin_ui_utils = require("@openzeppelin/ui-utils");
|
|
33
34
|
let _stellar_stellar_sdk = require("@stellar/stellar-sdk");
|
|
@@ -40,10 +41,10 @@ let _openzeppelin_relayer_sdk = require("@openzeppelin/relayer-sdk");
|
|
|
40
41
|
let _stellar_stellar_xdr_json_package_json = require("@stellar/stellar-xdr-json/package.json");
|
|
41
42
|
_stellar_stellar_xdr_json_package_json = __toESM(_stellar_stellar_xdr_json_package_json);
|
|
42
43
|
let lossless_json = require("lossless-json");
|
|
43
|
-
let _openzeppelin_ui_components = require("@openzeppelin/ui-components");
|
|
44
44
|
let lucide_react = require("lucide-react");
|
|
45
45
|
let react_hook_form = require("react-hook-form");
|
|
46
|
-
let
|
|
46
|
+
let lodash_es_startCase_js = require("lodash-es/startCase.js");
|
|
47
|
+
lodash_es_startCase_js = __toESM(lodash_es_startCase_js);
|
|
47
48
|
|
|
48
49
|
//#region src/utils/type-detection.ts
|
|
49
50
|
/**
|
|
@@ -6408,7 +6409,7 @@ function generateStellarDefaultField(parameter, contractSchema) {
|
|
|
6408
6409
|
const baseField = {
|
|
6409
6410
|
id: `field-${Math.random().toString(36).substring(2, 9)}`,
|
|
6410
6411
|
name: parameter.name || parameter.type,
|
|
6411
|
-
label: (0,
|
|
6412
|
+
label: (0, lodash_es_startCase_js.default)(parameter.displayName || parameter.name || parameter.type),
|
|
6412
6413
|
type: finalFieldType,
|
|
6413
6414
|
placeholder: enumMetadata ? `Select ${parameter.displayName || parameter.name || parameter.type}` : `Enter ${parameter.displayName || parameter.name || parameter.type}`,
|
|
6414
6415
|
helperText: parameter.description || "",
|
|
@@ -7035,10 +7036,16 @@ const CustomAccountDisplay = ({ className, size, variant, fullWidth }) => {
|
|
|
7035
7036
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
|
|
7036
7037
|
className: (0, _openzeppelin_ui_utils.cn)("flex items-center gap-2", fullWidth && "w-full", className),
|
|
7037
7038
|
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
|
|
7038
|
-
className: (0, _openzeppelin_ui_utils.cn)("flex flex-col", fullWidth && "flex-1"),
|
|
7039
|
-
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(
|
|
7040
|
-
|
|
7041
|
-
|
|
7039
|
+
className: (0, _openzeppelin_ui_utils.cn)("group flex flex-col", fullWidth && "flex-1"),
|
|
7040
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(_openzeppelin_ui_components.AddressDisplay, {
|
|
7041
|
+
address,
|
|
7042
|
+
variant: "inline",
|
|
7043
|
+
startChars: 4,
|
|
7044
|
+
endChars: 4,
|
|
7045
|
+
showTooltip: true,
|
|
7046
|
+
showCopyButton: true,
|
|
7047
|
+
showCopyButtonOnHover: true,
|
|
7048
|
+
className: (0, _openzeppelin_ui_utils.cn)(sizeProps.textSize, "font-sans font-medium")
|
|
7042
7049
|
}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
|
|
7043
7050
|
className: (0, _openzeppelin_ui_utils.cn)(sizeProps.subTextSize, "text-muted-foreground -mt-0.5"),
|
|
7044
7051
|
children: "Stellar Account"
|
|
@@ -7546,6 +7553,32 @@ var StellarAdapter = class {
|
|
|
7546
7553
|
|
|
7547
7554
|
//#endregion
|
|
7548
7555
|
//#region src/index.ts
|
|
7556
|
+
(0, _openzeppelin_ui_utils.validatePeerVersions)("@openzeppelin/adapter-stellar", {
|
|
7557
|
+
"@openzeppelin/ui-components": {
|
|
7558
|
+
installed: _openzeppelin_ui_components.VERSION,
|
|
7559
|
+
minimum: {
|
|
7560
|
+
"@openzeppelin/ui-components": "1.7.0",
|
|
7561
|
+
"@openzeppelin/ui-types": "1.12.0",
|
|
7562
|
+
"@openzeppelin/ui-utils": "1.4.0"
|
|
7563
|
+
}["@openzeppelin/ui-components"]
|
|
7564
|
+
},
|
|
7565
|
+
"@openzeppelin/ui-types": {
|
|
7566
|
+
installed: _openzeppelin_ui_types.VERSION,
|
|
7567
|
+
minimum: {
|
|
7568
|
+
"@openzeppelin/ui-components": "1.7.0",
|
|
7569
|
+
"@openzeppelin/ui-types": "1.12.0",
|
|
7570
|
+
"@openzeppelin/ui-utils": "1.4.0"
|
|
7571
|
+
}["@openzeppelin/ui-types"]
|
|
7572
|
+
},
|
|
7573
|
+
"@openzeppelin/ui-utils": {
|
|
7574
|
+
installed: _openzeppelin_ui_utils.VERSION,
|
|
7575
|
+
minimum: {
|
|
7576
|
+
"@openzeppelin/ui-components": "1.7.0",
|
|
7577
|
+
"@openzeppelin/ui-types": "1.12.0",
|
|
7578
|
+
"@openzeppelin/ui-utils": "1.4.0"
|
|
7579
|
+
}["@openzeppelin/ui-utils"]
|
|
7580
|
+
}
|
|
7581
|
+
});
|
|
7549
7582
|
const ecosystemDefinition = {
|
|
7550
7583
|
...require_metadata.ecosystemMetadata,
|
|
7551
7584
|
networks: require_networks.stellarNetworks,
|