2024-05-19 15:30:06 +00:00
|
|
|
/// Loads a schema from a file or a raw block.
|
|
|
|
/// This function returns a dictionary of structures
|
|
|
|
///
|
|
|
|
/// Supported formats: #schema.valid-extensions.map(e => raw("." + e)).join(", ")
|
2024-06-14 08:17:19 +00:00
|
|
|
/// - path-or-schema (str, raw, dictionary): If it is a string, defines the path to load. \
|
|
|
|
/// If it is a raw block, its content is directly parsed (the block's language will define the format to use) \
|
|
|
|
/// If it is a dictionary, it directly defines the schema structure
|
2024-05-19 15:30:06 +00:00
|
|
|
/// -> dictionary
|
|
|
|
#let load(path-or-schema) = {}
|
|
|
|
|
|
|
|
/// Renders the given schema
|
|
|
|
/// This functions
|
2024-06-14 09:20:32 +00:00
|
|
|
/// - schema (dictionary): A schema dictionary, as returned by #doc-ref("schema.load")
|
2024-05-19 15:30:06 +00:00
|
|
|
/// - config (auto, dictionary): The configuration parameters, as returned by #doc-ref("config.config")
|
2024-06-13 10:23:22 +00:00
|
|
|
/// - width (ratio, length): The width of the generated figure
|
2024-06-14 09:20:32 +00:00
|
|
|
#let render(schema, config: auto, width: 100%) = {}
|