[package]
name = "subxt-core"
version.workspace = true
authors.workspace = true
edition.workspace = true
rust-version.workspace = true
publish = true

license.workspace = true
readme = "README.md"
repository.workspace = true
documentation.workspace = true
homepage.workspace = true
description = "A no-std compatible subset of Subxt's functionality"
keywords = ["parity", "subxt", "extrinsic", "no-std"]

[features]
default = ["std"]
std = [
    "codec/std",
    "scale-info/std",
    "frame-metadata/std",
    "subxt-metadata/std",
    "hex/std",
    "serde/std",
    "serde_json/std",
    "tracing/std",
    "impl-serde/std",
    "primitive-types/std",
    "sp-crypto-hashing/std",
]

[dependencies]
codec = { package = "parity-scale-codec", workspace = true, default-features = false, features = ["derive"] }
frame-decode = { workspace = true }
scale-info = { workspace = true, default-features = false, features = ["bit-vec"] }
scale-value = { workspace = true, default-features = false }
scale-bits = { workspace = true, default-features = false }
scale-decode = { workspace = true, default-features = false, features = ["derive", "primitive-types"] }
scale-encode = { workspace = true, default-features = false, features = ["derive", "primitive-types", "bits"] }
frame-metadata = { workspace = true, default-features = false }
subxt-metadata = { workspace = true, default-features = false }
derive-where = { workspace = true }
hex = { workspace = true }
serde = { workspace = true, default-features = false, features = ["derive"] }
serde_json = { workspace = true, default-features = false, features = ["raw_value", "alloc"] }
tracing = { workspace = true, default-features = false }
sp-crypto-hashing = { workspace = true }
hashbrown = { workspace = true }
thiserror = { workspace = true, default-features = false }

# For ss58 encoding AccountId32 to serialize them properly:
base58 = { workspace = true }
blake2 = { workspace = true }

# Provides some deserialization, types like U256/H256 and hashing impls like twox/blake256:
impl-serde = { workspace = true, default-features = false }
primitive-types = { workspace = true, default-features = false, features = ["codec", "serde_no_std", "scale-info"] }

# AccountId20
keccak-hash = { workspace = true}

[dev-dependencies]
assert_matches = { workspace = true }
bitvec = { workspace = true }
codec = { workspace = true, features = ["derive", "bit-vec"] }
subxt-macro = { workspace = true }
subxt-signer = { workspace = true, features = ["sr25519", "subxt"] }
sp-core = { workspace = true }
sp-keyring = { workspace = true }
hex = { workspace = true }

[package.metadata.docs.rs]
default-features = true
rustdoc-args = ["--cfg", "docsrs"]

[package.metadata.playground]
default-features = true

[lints]
workspace = true
