Skip to main content

Crate dc_figma_import

Crate dc_figma_import 

Source
Expand description

dc_figma_import fetches a document from Figma and converts nodes from the document to toolkit_schema Views, which can then be further customized (changing text or style) and presented in other components that implement logic.

The goal of this crate is to perform the mapping from Figma to the toolkit; it does not provide any kind of UI logic mapping.

Re-exports§

pub use remote_cache::RemoteNodeCache;

Modules§

animation_override
This file contains the conversions from the JSON animation specification to the protobuf animation specification. The JSON structs are defined in animation_spec_schema.rs. The protobuf structs are generated from animations.proto.
animation_spec_schema
content_hash
Content hashing for View diffing and incremental updates.
http_client
Shared HTTP client for Figma API calls.
library_resolver
Library dependency discovery and resolution.
meter_schema
toolkit_style contains all of the style-related types that toolkit_schema::View uses.
node_tracker
Tracks top-level node structure for selective re-fetching.
reaction_schema
remote_cache
Persistent cache for remote node responses across poll cycles.
scalableui_schema
shader_schema
tools

Structs§

Color
DesignComposeDefinition
DesignComposeDefinitionHeader
Document
Document is used to access and maintain an entire Figma document, including components and image resources. It can be updated if the source document has changed since this structure was created.
ImageContextSession
Rectangle
View
ViewData

Enums§

Error
Combined error type for all errors that can occur working with Figma documents.
HiddenNodePolicy
NodeQuery
ProxyConfig

Functions§

load_design_def
A helper method to load a DesignCompose Definition from a file.
save_design_def
A helper method to save serialized figma design docs.