dev-protocol / dev-protocol/dev-elements

[FEATURE] <dev-when-staked>

未关闭
#118 1 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

还没有人认领这个 Issue。

enhancement
主要语言
TypeScript
星标
7
派生
1
PR 合并指标
30 天内没有已合并 PR

描述

Detailed description

This issue doesn't have a more in-depth spec, it just suggests a feature.


By declaring HTML as follows, the viewer's staking position is verified, the request to src is made only when the require condition is fulfilled, and its response is applied to the template child element and rendered.

This architecture is based on amp-list.

<dev-when-staked connection="CONNECTION_ID" destination="0x..." network="NETWORK_NAME" require="300" src="https://example.com/data...">
    <template>
        ...
    </template>
    <p>Placeholder while waiting to meet require</p>
</dev-when-staked>
Options
  • *connection: the id of dev-connection element #126
  • *destination: the address of the staking destination
  • *network: the network name
  • *require: the minimum staking amount to unlock content
  • *src: the content source
Context

<dev-when-staked> is useful for achieving staking paywalls with minimal coding.

Possible implementation

No response

Additional information

No response

Code of Conduct
  • I agree to follow this project's Code of Conduct

贡献指南

这个仓库没有索引到贡献指南

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

调研方向

首先检查提议的 dev-connection 元素 (#126) 以及 issue 中引用的 amp-list 架构。在实现之前,定义组件行为以及 staking 验证、条件性 src 请求、模板渲染和占位内容的验收标准;未确定任何文件或测试。

由索引模型根据 Issue 内容生成。

评估

技术栈
typescript
领域
blockchain, frontend
Issue 类型
功能
难度
5/5
预计耗时
一周以上
活跃度
停滞
描述清晰度
需要澄清
新手友好度
20/100

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。