Skip to content

Conversation

@findolor
Copy link
Contributor

@findolor findolor commented Dec 25, 2025

Motivation

See issues:

The token spec currently lacks support for token logos/icons. Token logos are a common requirement for UI applications and are already part of the tokenlists.org standard that we reference via using-tokens-from. Adding this field allows tokens defined directly in YAML to include logo URIs, bringing parity with tokens imported from external token lists.

Solution

Added an optional logo-uri field to the token definition in ob-yaml.md:

  • Added logo-uri to the optional fields list with the note "(fetch from token list)" to indicate the data source
  • Updated the example token definition to demonstrate usage
  • Used kebab-case naming (logo-uri) to match existing field conventions like network-id, vault-id, and deployment-block

Checks

By submitting this for review, I'm confirming I've done the following:

  • made this PR as small as possible
  • [ ] unit-tested any new functionality
  • linked any relevant issues or PRs
  • included screenshots (if this involves a front-end change)

Summary by CodeRabbit

  • New Features
    • Added optional logo-uri field to tokens to display token logos sourced from token lists. Example configurations updated to reflect this new field.

✏️ Tip: You can customize this high-level summary in your review settings.

@findolor findolor requested review from 0xgleb and hardyjosh December 25, 2025 06:34
@findolor findolor self-assigned this Dec 25, 2025
@coderabbitai
Copy link

coderabbitai bot commented Dec 25, 2025

Walkthrough

The PR adds an optional logo-uri field to the Tokens specification in ob-yaml.md, sourced from token lists. The example is updated to demonstrate this new field for eth-usdc. No behavioral or validation logic changes are introduced.

Changes

Cohort / File(s) Summary
Specification Documentation
ob-yaml.md
Introduces optional logo-uri token field fetched from token lists; updates eth-usdc example to include the new field

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~5 minutes

Possibly related PRs

Suggested reviewers

  • hardyjosh

Pre-merge checks and finishing touches

✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately and concisely describes the main change: adding an optional logo-uri field to the token specification.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
✨ Finishing touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch 2025-12-25-tokens-logo-uri

📜 Recent review details

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between abcbe3f and 4f08574.

📒 Files selected for processing (1)
  • ob-yaml.md
🧰 Additional context used
🧠 Learnings (2)
📓 Common learnings
Learnt from: findolor
Repo: rainlanguage/specs PR: 35
File: ob-yaml.md:17-19
Timestamp: 2025-06-04T05:56:12.485Z
Learning: The `spec-version` field in ob-yaml.md is newly introduced and has no existing usage, so renaming it to `version` requires no backward compatibility considerations or deprecation notes.
📚 Learning: 2025-06-04T05:56:12.485Z
Learnt from: findolor
Repo: rainlanguage/specs PR: 35
File: ob-yaml.md:17-19
Timestamp: 2025-06-04T05:56:12.485Z
Learning: The `spec-version` field in ob-yaml.md is newly introduced and has no existing usage, so renaming it to `version` requires no backward compatibility considerations or deprecation notes.

Applied to files:

  • ob-yaml.md
🔇 Additional comments (2)
ob-yaml.md (2)

178-183: Optional field addition is consistent and well-motivated.

The logo-uri field follows existing kebab-case naming conventions and the annotation "(fetch from token list)" aligns with the pattern used for other optional fields like decimals and label. This addition directly addresses the motivation to support token logos from the tokenlists.org standard referenced by using-tokens-from.


185-197: Example correctly demonstrates the new optional field.

The updated example for eth-usdc includes the logo-uri field, while the eth-dai example omits it to clearly show optionality. The field ordering in the example follows the documented sequence (required fields, then optional fields in the listed order).


Comment @coderabbitai help to get the list of available commands and usage tips.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants