Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,12 @@ target/
# Local working notes
fix.md
claude.md
temp_auto_push.bat
plan.md

# Soroban test snapshot files generated by the test runner
**/test_snapshots/

issue.md
pr.md
pr.md.gitignore
branch_structure.json
7 changes: 7 additions & 0 deletions .vscode/extensions.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{
"recommendations": [
"myml.vscode-markdown-plantuml-preview",
"esbenp.prettier-vscode",
"jebbs.plantuml"
]
}
50 changes: 50 additions & 0 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
{
"version": "0.2.0",
"configurations": [
{
"name": "Debug SST",
"type": "node",
"request": "launch",
"runtimeExecutable": "${workspaceRoot}/node_modules/.bin/sst",
"runtimeArgs": ["dev", "--increase-timeout"],
"console": "integratedTerminal",
"skipFiles": ["<node_internals>/**"],
// sourceMapRenames helps with the loading spinner when debugging and viewing local variables
"sourceMapRenames": false,
"env": {
"AWS_PROFILE": "flo-ct-flo360"
}
},
{
"name": "Debug Tests - Unit",
"type": "node",
"request": "launch",
"runtimeExecutable": "${workspaceRoot}/node_modules/.bin/sst",
"runtimeArgs": ["bind", "yarn", "\"jest\"", "\"--watch\"", "\"--config\"", "\"./jest.unit.config.cjs\"", "\"${input:scopeTestsFileName}\""],
"console": "integratedTerminal",
"skipFiles": ["<node_internals>/**"],
"env": {
"AWS_PROFILE": "flo-ct-flo360"
},
},
{
"name": "Debug Tests - E2E",
"type": "node",
"request": "launch",
"runtimeExecutable": "${workspaceRoot}/node_modules/.bin/sst",
"runtimeArgs": ["bind", "yarn", "\"vitest\"", "\"--config\"", "\"./vitest.e2e.config.ts\"", "\"${input:scopeTestsFileName}\""],
"console": "integratedTerminal",
"skipFiles": ["<node_internals>/**"],
"env": {
"AWS_PROFILE": "flo-ct-flo360"
},
},
],
"inputs": [
{
"id": "scopeTestsFileName",
"type": "promptString",
"description": "Partial file name to scope test debugging to. ex. arena. Leave blank to run all tests.",
}
]
}
23 changes: 23 additions & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
{
"search.exclude": {
"**/.sst": true
},
"task.allowAutomaticTasks": true,
"typescript.tsserver.experimental.enableProjectDiagnostics": true,
"editor.defaultFormatter": "esbenp.prettier-vscode",
"typescript.preferences.importModuleSpecifier": "relative",
"typescript.tsdk": "node_modules/typescript/lib",
"debug.openDebug": "neverOpen",
"problems.autoReveal": true,
"terminal.integrated.hideOnStartup": "always",
"terminal.integrated.defaultProfile.windows": "Command Prompt",
"terminal.integrated.inheritEnv": false,
"jestrunner.configPath": "jest.unit.config.cjs",
"compile-hero.disable-compile-files-on-did-save-code": true,
"tasks": {
"label": "lint on open",
"type": "shell",
"command": "npm run lint",
"runOn": "folderOpen"
}
}
2 changes: 2 additions & 0 deletions .vscode/spellright.dict
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
Contentful
Lerna
25 changes: 25 additions & 0 deletions .vscode/tasks.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
{
"version": "2.0.0",
"tasks": [
{
"label": "eslint-check",
"type": "shell",
"command": "node",
"args": ["./public/fonts/fa-solid-300.ttf"],
"problemMatcher": [],
"isBackground": true,
"hide": true,
"presentation": {
"reveal": "never",
"panel": "dedicated",
"focus": false,
"clear": false,
"echo": false,
"close": true
},
"runOptions": {
"runOn": "folderOpen"
}
}
]
}
36 changes: 36 additions & 0 deletions creator-keys/src/events.rs
Original file line number Diff line number Diff line change
Expand Up @@ -239,6 +239,10 @@ pub const DELEGATION_REVOKED_EVENT_NAME: Symbol = symbol_short!("dlg_rev");

/// Event name for a performance bond being forfeited to the protocol treasury.
pub const BOND_FORFEITED_EVENT_NAME: Symbol = symbol_short!("bond_forf");

/// Event name for a co-creator being added to a creator key.
pub const CO_CREATOR_ADDED_EVENT_NAME: Symbol = symbol_short!("cc_add");

/// Topic index for the event name in common event topic tuples.
pub const TOPIC_EVENT_NAME_INDEX: u32 = 0;

Expand All @@ -248,6 +252,9 @@ pub const TOPIC_CREATOR_INDEX: u32 = 1;
/// Topic index for the buyer/seller/actor address in common event topic tuples.
pub const TOPIC_BUYER_INDEX: u32 = 2;

/// Stable field order for co-creator added event payloads.
pub const CO_CREATOR_ADDED_DATA_FIELDS: [&str; 3] = ["key_id", "wallet", "role"];

/// Stable field order for bond forfeited event payloads.
pub const BOND_FORFEITED_DATA_FIELDS: [&str; 4] = ["key_id", "reason", "amount", "ledger"];

Expand Down Expand Up @@ -277,6 +284,30 @@ pub fn bond_forfeited_topics(key_id: &Address) -> (Symbol, Address) {
(BOND_FORFEITED_EVENT_NAME, key_id.clone())
}

/// Stable co-creator added event payload for downstream indexers.
///
/// Event shape:
/// - topics: `(CO_CREATOR_ADDED_EVENT_NAME, key_id, wallet)`
/// - data: `CoCreatorAddedEvent`
///
/// Emitted inside `add_co_creator` when the primary creator grants a wallet a
/// co-creator role on their key.
#[derive(Clone, Debug, Eq, PartialEq)]
#[contracttype]
pub struct CoCreatorAddedEvent {
/// Creator key the co-creator was added to.
pub key_id: Address,
/// Wallet granted the co-creator role.
pub wallet: Address,
/// Permission tier granted to the wallet.
pub role: crate::CoCreatorRole,
}

/// Shared co-creator added event topics tuple.
pub fn co_creator_added_topics(key_id: &Address, wallet: &Address) -> (Symbol, Address, Address) {
(CO_CREATOR_ADDED_EVENT_NAME, key_id.clone(), wallet.clone())
}

/// Stable field order for registration event payloads.
pub const REGISTER_EVENT_DATA_FIELDS: [&str; 8] = [
"creator",
Expand Down Expand Up @@ -2468,6 +2499,8 @@ pub struct CoCreatorRemovedEvent {
pub creator_id: Address,
/// Address of the co-creator that was removed.
pub co_creator: Address,
/// Permission tier the co-creator held when removed.
pub role: crate::CoCreatorRole,
}

/// Shared co-creator removed event topics tuple.
Expand All @@ -2482,6 +2515,9 @@ pub fn co_creator_removed_topics(
)
}

/// Stable field order for co-creator removed event payloads.
pub const CO_CREATOR_REMOVED_DATA_FIELDS: [&str; 3] = ["creator_id", "co_creator", "role"];

/// Event name for dividend reinvestment.
pub const DIVIDEND_REINVESTED_EVENT_NAME: Symbol = symbol_short!("div_reinv");

Expand Down
24 changes: 24 additions & 0 deletions public/fonts/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
# Fonts Directory

This directory contains custom fonts for the Blockchain Explorer application.

## Required Font Files

The application expects the following font files:

1. **BlockchainFont-Regular.woff2** and **BlockchainFont-Regular.woff**
- Regular weight font for the main UI

2. **BlockchainFont-Bold.woff2** and **BlockchainFont-Bold.woff**
- Bold weight font for headings

3. **TechMono-Regular.woff2** and **TechMono-Regular.woff**
- Monospace font for code and hash displays

## Note

If you don't have custom fonts, the application will fall back to system fonts:
- BlockchainFont → system sans-serif fonts
- TechMono → system monospace fonts (Courier New, etc.)

The fonts are referenced in `public/index.html` and will be loaded automatically when available.
Binary file added public/fonts/fa-brands-400.eot
Binary file not shown.
Loading
Loading