

const require_jwa = require('../../jwa.js');
const require_ecPublicKey = require('./ecPublicKey.js');

//#region src/modules/kms/jwk/kty/ec/Secp256k1PublicJwk.ts
var Secp256k1PublicJwk = class Secp256k1PublicJwk {
	constructor(jwk) {
		this.jwk = jwk;
		this.supportdEncryptionKeyAgreementAlgorithms = Secp256k1PublicJwk.supportdEncryptionKeyAgreementAlgorithms;
		this.supportedSignatureAlgorithms = Secp256k1PublicJwk.supportedSignatureAlgorithms;
		this.multicodecPrefix = Secp256k1PublicJwk.multicodecPrefix;
	}
	get publicKey() {
		return {
			crv: this.jwk.crv,
			kty: this.jwk.kty,
			publicKey: require_ecPublicKey.ecPublicJwkToPublicKey(this.jwk)
		};
	}
	get compressedPublicKey() {
		return {
			crv: this.jwk.crv,
			kty: this.jwk.kty,
			publicKey: require_ecPublicKey.ecPublicJwkToPublicKey(this.jwk, { compressed: true })
		};
	}
	get multicodec() {
		return require_ecPublicKey.ecPublicJwkToPublicKey(this.jwk, { compressed: true });
	}
	static fromPublicKey(publicKey) {
		return new Secp256k1PublicJwk(require_ecPublicKey.ecPublicKeyToPublicJwk(publicKey, "secp256k1"));
	}
	static fromMulticodec(multicodec) {
		return new Secp256k1PublicJwk(require_ecPublicKey.ecPublicKeyToPublicJwk(multicodec, "secp256k1"));
	}
};
Secp256k1PublicJwk.supportedSignatureAlgorithms = [require_jwa.KnownJwaSignatureAlgorithms.ES256K];
Secp256k1PublicJwk.supportdEncryptionKeyAgreementAlgorithms = [require_jwa.KnownJwaKeyAgreementAlgorithms.ECDH_ES];
Secp256k1PublicJwk.multicodecPrefix = 231;

//#endregion
exports.Secp256k1PublicJwk = Secp256k1PublicJwk;